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

Fix APIRoute type #3344

Merged
merged 3 commits into from
May 11, 2022
Merged

Fix APIRoute type #3344

merged 3 commits into from
May 11, 2022

Conversation

matthewp
Copy link
Contributor

@matthewp matthewp commented May 11, 2022

Screen Shot 2022-05-11 at 9 09 21 AM

Changes

Testing

Our TS types are currently not tested :/

Docs

N/A, this API is already documented.

@changeset-bot
Copy link

changeset-bot bot commented May 11, 2022

🦋 Changeset detected

Latest commit: 5efb514

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
astro Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label May 11, 2022
Copy link
Contributor

@bholmesdev bholmesdev left a comment

Choose a reason for hiding this comment

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

A shame we're losing the @deprecated notice here, but I won't stop us if we're enroute to a fix

Copy link
Member

@natemoo-re natemoo-re left a comment

Choose a reason for hiding this comment

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

LGTM! Noticed we dropped the return await, any reason for that?

return await handler.call(mod, proxy, request);
return handler.call(mod, proxy, request);
Copy link
Member

Choose a reason for hiding this comment

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

Does this change anything critical?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No, VScode said it wasn't needed.

Copy link
Member

Choose a reason for hiding this comment

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

Cool, not blocking, just curious.

@matthewp matthewp merged commit 46cd8b9 into main May 11, 2022
@matthewp matthewp deleted the apiroute-type branch May 11, 2022 21:07
@github-actions github-actions bot mentioned this pull request May 11, 2022
@shiftlabs1
Copy link

Please see #3343 (comment) . This does give errors when using async/await in a function

SiriousHunter pushed a commit to SiriousHunter/astro that referenced this pull request Feb 3, 2023
* Fix APIRoute type

* Adds a changeset

* Update usage of the two API route signatures
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🐛 BUG: APIRoute type problems
4 participants