Skip to content

Commit

Permalink
Always strip leading / from S3 keys
Browse files Browse the repository at this point in the history
  • Loading branch information
rowanseymour committed Aug 22, 2024
1 parent 4f729ae commit ccc989e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion archives/s3.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ func GetS3FileInfo(ctx context.Context, s3Client *s3x.Service, fileURL string) (
}

bucket := strings.Split(u.Host, ".")[0]
path := u.Path
path := strings.TrimPrefix(u.Path, "/")

head, err := s3Client.Client.HeadObject(
ctx,
Expand Down

0 comments on commit ccc989e

Please sign in to comment.