From 3ba62ab6881798808643490d47e737521190ce1a Mon Sep 17 00:00:00 2001 From: Leonardo Medici Date: Tue, 27 Aug 2024 17:44:44 +0200 Subject: [PATCH] Prevent crash if key attribute is missing --- src/BrefServiceProvider.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/BrefServiceProvider.php b/src/BrefServiceProvider.php index 931eec6..2a61d50 100644 --- a/src/BrefServiceProvider.php +++ b/src/BrefServiceProvider.php @@ -162,7 +162,7 @@ private function fixAwsCredentialsConfig(): void continue; } // If a different key is in the config than in the environment variables - if ($connection['key'] && $connection['key'] !== $accessKeyId) { + if (isset($connection['key']) && $connection['key'] !== $accessKeyId) { continue; } @@ -175,7 +175,7 @@ private function fixAwsCredentialsConfig(): void continue; } // If a different key is in the config than in the environment variables - if ($disk['key'] && $disk['key'] !== $accessKeyId) { + if (isset($disk['key']) && $disk['key'] !== $accessKeyId) { continue; } @@ -188,7 +188,7 @@ private function fixAwsCredentialsConfig(): void continue; } // If a different key is in the config than in the environment variables - if ($store['key'] && $store['key'] !== $accessKeyId) { + if (isset($store['key']) && $store['key'] !== $accessKeyId) { continue; }