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

[SDK-4318] Enable responses from custom middleware #1265

Merged
merged 1 commit into from
Jun 23, 2023

Conversation

adamjmcgrath
Copy link
Contributor

📋 Changes

Enable responses from withMiddlewareAuthRequired custom middleware. eg

import { withMiddlewareAuthRequired } from '@auth0/nextjs-auth0/edge';

export default withMiddlewareAuthRequired(() => NextResponse.json({ hello: 'world' }));

(Also including a fix for #1253 for the beta)

📎 References

fixes #1150

🎯 Testing

@adamjmcgrath adamjmcgrath added the review:small Small review label Jun 23, 2023
@adamjmcgrath adamjmcgrath requested a review from a team as a code owner June 23, 2023 14:22
@vercel
Copy link

vercel bot commented Jun 23, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Updated (UTC)
nextjs-auth0 ⬜️ Ignored (Inspect) Jun 23, 2023 2:22pm

@Widcket
Copy link
Contributor

Widcket commented Jun 23, 2023

Doesn't this PR overwrite the changes made in #1263? Should that PR be closed?

@adamjmcgrath
Copy link
Contributor Author

This one's for v3, #1263 is for v2

@Widcket
Copy link
Contributor

Widcket commented Jun 23, 2023

My bad 🤦🏻‍♀️

@adamjmcgrath adamjmcgrath merged commit 5f33ac4 into beta Jun 23, 2023
3 checks passed
@adamjmcgrath adamjmcgrath deleted the response-from-mw branch June 23, 2023 16:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
review:small Small review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants