Skip to content

Commit

Permalink
Merge pull request #159 from DocLM/bugfix/missing-key
Browse files Browse the repository at this point in the history
Prevent crash if key attribute is missing
  • Loading branch information
mnapoli authored Aug 27, 2024
2 parents 7727eb0 + 3ba62ab commit d97d1bc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/BrefServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}

Expand All @@ -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;
}

Expand All @@ -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;
}

Expand Down

0 comments on commit d97d1bc

Please sign in to comment.