diff options
author | Thomas Citharel <tcit@tcit.fr> | 2023-06-26 16:43:07 +0200 |
---|---|---|
committer | backportbot-nextcloud[bot] <backportbot-nextcloud[bot]@users.noreply.github.com> | 2023-08-31 21:21:16 +0000 |
commit | fe618feeb094c4348153c449ec79d9d92027d953 (patch) | |
tree | e4f007dee82e4e561a47cd0e24313ff7ee3c92b6 /lib | |
parent | 3519f20add91ea990b9bd049e2c028b7915cfca3 (diff) | |
download | nextcloud-server-fe618feeb094c4348153c449ec79d9d92027d953.tar.gz nextcloud-server-fe618feeb094c4348153c449ec79d9d92027d953.zip |
fix(s3): fix handling verify_bucket_exists parameter
If 'verify_bucket_exists' is set to false in the config.php s3 configuration, it's supposed to avoid
verifying that the bucket exists. However empty(falsy) will always return true, so this condition
would not work.
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/ObjectStore/S3ConnectionTrait.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Files/ObjectStore/S3ConnectionTrait.php b/lib/private/Files/ObjectStore/S3ConnectionTrait.php index deb03571c76..49942b385bc 100644 --- a/lib/private/Files/ObjectStore/S3ConnectionTrait.php +++ b/lib/private/Files/ObjectStore/S3ConnectionTrait.php @@ -92,7 +92,7 @@ trait S3ConnectionTrait { if (!isset($params['port']) || $params['port'] === '') { $params['port'] = (isset($params['use_ssl']) && $params['use_ssl'] === false) ? 80 : 443; } - $params['verify_bucket_exists'] = empty($params['verify_bucket_exists']) ? true : $params['verify_bucket_exists']; + $params['verify_bucket_exists'] = $params['verify_bucket_exists'] ?? true; $this->params = $params; } |