summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorCarl Schwan <carl@carlschwan.eu>2022-08-03 11:23:12 +0200
committerGitHub <noreply@github.com>2022-08-03 11:23:12 +0200
commitd9a7dfa342d796b0b6ec6cac1b696caea696e037 (patch)
tree9bab49d0696c1b3d00552ae027f5a052767edd8b /apps
parenta08f995e80ec174081a8aa9d016dd834218e5dd7 (diff)
parent46167121fc49704f7566fc9aa7d168079c860d0c (diff)
downloadnextcloud-server-d9a7dfa342d796b0b6ec6cac1b696caea696e037.tar.gz
nextcloud-server-d9a7dfa342d796b0b6ec6cac1b696caea696e037.zip
Merge pull request #33392 from nextcloud/backport/33280/stable23
[stable23] handle AccessDenied error when checking if external s3 support versions
Diffstat (limited to 'apps')
-rw-r--r--apps/files_external/lib/Lib/Storage/AmazonS3.php2
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 cfd78689fa4..62bff08895b 100644
--- a/apps/files_external/lib/Lib/Storage/AmazonS3.php
+++ b/apps/files_external/lib/Lib/Storage/AmazonS3.php
@@ -747,7 +747,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;