diff options
author | Roeland Jago Douma <rullzer@users.noreply.github.com> | 2018-02-19 17:09:36 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-19 17:09:36 +0100 |
commit | 7ad1e13961eb48d3cf61c77faddfc6507f77e6ee (patch) | |
tree | 1f1619509e4ef751cab242ef47ab9c79baad205d | |
parent | 4e6d98ea8c9219c5c04209572e7b6dd7d7f1dd8e (diff) | |
parent | 48ea714341d0025d793abd324251c134e74e230c (diff) | |
download | nextcloud-server-7ad1e13961eb48d3cf61c77faddfc6507f77e6ee.tar.gz nextcloud-server-7ad1e13961eb48d3cf61c77faddfc6507f77e6ee.zip |
Merge pull request #8158 from nextcloud/s3-minio
Use a more widely available method to test s3 settings
-rw-r--r-- | apps/files_external/lib/Lib/Storage/AmazonS3.php | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/apps/files_external/lib/Lib/Storage/AmazonS3.php b/apps/files_external/lib/Lib/Storage/AmazonS3.php index f06247c3690..459f9b80e12 100644 --- a/apps/files_external/lib/Lib/Storage/AmazonS3.php +++ b/apps/files_external/lib/Lib/Storage/AmazonS3.php @@ -571,13 +571,10 @@ class AmazonS3 extends \OC\Files\Storage\Common { } public function test() { - $test = $this->getConnection()->getBucketAcl(array( - 'Bucket' => $this->bucket, - )); - if (isset($test) && !is_null($test->getPath('Owner/ID'))) { - return true; - } - return false; + $this->getConnection()->headBucket([ + 'Bucket' => $this->bucket + ]); + return true; } public function getId() { |