Fix error message style issue for staticcheck
Co-authored-by: yxxhero <11087727+yxxhero@users.noreply.github.com>
This commit is contained in:
parent
3facc3cdac
commit
b6098e4787
|
|
@ -480,7 +480,7 @@ func (g *S3Getter) S3FileExists(path string) (string, error) {
|
||||||
}
|
}
|
||||||
resp, err := s3Client.GetBucketLocation(context.TODO(), getBucketLocationInput)
|
resp, err := s3Client.GetBucketLocation(context.TODO(), getBucketLocationInput)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return "", fmt.Errorf("Error: Failed to retrieve bucket location: %v\n", err)
|
return "", fmt.Errorf("failed to retrieve bucket location: %v", err)
|
||||||
}
|
}
|
||||||
if resp == nil || string(resp.LocationConstraint) == "" {
|
if resp == nil || string(resp.LocationConstraint) == "" {
|
||||||
g.Logger.Debugf("Bucket has no location Assuming us-east-1")
|
g.Logger.Debugf("Bucket has no location Assuming us-east-1")
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue