Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ensure that S3 Push does not double-slash at beginning #365

Merged
merged 1 commit into from
Nov 3, 2024

Conversation

deitch
Copy link
Collaborator

@deitch deitch commented Nov 3, 2024

When passing the target key to S3 via the library as:

	_, err = uploader.Upload(context.TODO(), &s3.PutObjectInput{
		Bucket: aws.String(bucket),
		Key:    aws.String(path.Join(key, target)),
		Body:   f,
	})

It expects the Key to start without a slash, as it always adds one. This change ensures that it always is clean.

Signed-off-by: Avi Deitcher <avi@deitcher.net>
@deitch deitch merged commit 3f3f9c5 into master Nov 3, 2024
2 checks passed
@deitch deitch deleted the remove-leading-slash branch November 3, 2024 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant