Merge pull request #2995 from alrs/fix-swallowed-vfs-error

Fix swallowed err variable in vfs package
This commit is contained in:
Chris Love 2017-07-19 09:27:25 -06:00 committed by GitHub
commit b94dd9e7d4
1 changed files with 3 additions and 1 deletions

View File

@ -130,7 +130,9 @@ func (s *S3Context) getRegionForBucket(bucket string) (string, error) {
var response *s3.GetBucketLocationOutput
s3Client, err := s.getClient(awsRegion)
if err != nil {
return "", fmt.Errorf("error connecting to S3: %s", err)
}
// Attempt one GetBucketLocation call the "normal" way (i.e. as the bucket owner)
response, err = s3Client.GetBucketLocation(request)