From 2828a4b1e049f5e19127297dc40e073a26a8c5e1 Mon Sep 17 00:00:00 2001 From: Matthew Penner Date: Fri, 14 Oct 2022 11:00:10 -0600 Subject: [PATCH] fix AssetManifestService error when loading the panel --- app/Services/Helpers/AssetHashService.php | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/app/Services/Helpers/AssetHashService.php b/app/Services/Helpers/AssetHashService.php index ef29c03a9..2e1c1aaa6 100644 --- a/app/Services/Helpers/AssetHashService.php +++ b/app/Services/Helpers/AssetHashService.php @@ -15,7 +15,7 @@ class AssetHashService private Filesystem $filesystem; - protected static mixed $manifest; + protected static mixed $manifest = null; /** * AssetHashService constructor. @@ -99,9 +99,13 @@ class AssetHashService */ protected function manifest(): array { - return self::$manifest ?: self::$manifest = json_decode( - $this->filesystem->get(self::MANIFEST_PATH), - true - ); + if (static::$manifest === null) { + self::$manifest = json_decode( + $this->filesystem->get(self::MANIFEST_PATH), + true + ); + } + + return static::$manifest; } }