diff options
author | Matthieu Gallien <matthieu.gallien@nextcloud.com> | 2022-07-19 16:20:44 +0200 |
---|---|---|
committer | Matthieu Gallien (Rebase PR Action) <matthieu_gallien@yahoo.fr> | 2022-07-28 09:20:12 +0000 |
commit | 54c05bcdb96fcbab8a8c552e6558dc18b1571af3 (patch) | |
tree | e4a46d7e5a2c07536caeb391551395217565143d /apps/files_external/lib/Lib/Storage | |
parent | d2d408bba763accf5873e2a3a0deb8629e0073ac (diff) | |
download | nextcloud-server-54c05bcdb96fcbab8a8c552e6558dc18b1571af3.tar.gz nextcloud-server-54c05bcdb96fcbab8a8c552e6558dc18b1571af3.zip |
handle AccessDenied error when checking if external s3 support versions
Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
Diffstat (limited to 'apps/files_external/lib/Lib/Storage')
-rw-r--r-- | apps/files_external/lib/Lib/Storage/AmazonS3.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_external/lib/Lib/Storage/AmazonS3.php b/apps/files_external/lib/Lib/Storage/AmazonS3.php index 6ebbed33a87..d5b8eff6fe5 100644 --- a/apps/files_external/lib/Lib/Storage/AmazonS3.php +++ b/apps/files_external/lib/Lib/Storage/AmazonS3.php @@ -744,7 +744,7 @@ class AmazonS3 extends \OC\Files\Storage\Common { return $result->get('Status') === 'Enabled'; } catch (S3Exception $s3Exception) { // This is needed for compatibility with Storj gateway which does not support versioning yet - if ($s3Exception->getAwsErrorCode() === 'NotImplemented') { + if ($s3Exception->getAwsErrorCode() === 'NotImplemented' || $s3Exception->getAwsErrorCode() === 'AccessDenied') { return false; } throw $s3Exception; |