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

feat: local support for presigned url #476

Merged
merged 4 commits into from
Oct 30, 2023
Merged

Conversation

thantos
Copy link
Contributor

@thantos thantos commented Oct 30, 2023

Closes #341

  • Fixed: bucket names were using token literals instead of resolved values.

@thantos thantos marked this pull request as ready for review October 30, 2023 22:10
@thantos thantos requested a review from sam-goodwin October 30, 2023 22:11
Comment on lines 202 to 204
const body = req.body
? JSON.stringify(req.body)
: await getBody(req);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks weird. Why are you stringifying the body?

Also, when I hacked around this, I had to be careful about handling OPTIONS pre-flight requests when calling put on the front end.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ohh, yeah, OPTIONS is a good point. I think I'll just need to let unhandled methods pass through to the normal handler.

I was stringifying here because this logic was originally AFTER the JSON body parser, but now it is before so I can remove this logic.

};
}

public decodeAsyncUrlKey(
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand the name "decode async url key"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lol, I let the AI name this and forgot to change it.

@thantos thantos merged commit c4c7779 into main Oct 30, 2023
@thantos thantos deleted the sussman/feat/local_presigned branch October 30, 2023 22:55
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.

Support presigned bucket urls in local
2 participants