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: show experimental api warning only in dev and only once #4816

Merged
merged 6 commits into from Jul 2, 2022

Conversation

ndom91
Copy link
Member

@ndom91 ndom91 commented Jul 2, 2022

☕️ Reasoning

Show [next-auth][warn][EXPERIMENTAL_API] warning for the unstable_getServerSession API only once and only in NODE_ENV=development.

🧢 Checklist

  • Documentation
  • Tests
  • Ready to be merged

🎫 Affected issues

Please scout and link issues that might be solved by this PR.

Fixes: INSERT_ISSUE_LINK_HERE

📌 Resources

@vercel
Copy link

vercel bot commented Jul 2, 2022

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

1 Ignored Deployment
Name Status Preview Updated
next-auth ⬜️ Ignored (Inspect) Jul 2, 2022 at 0:16AM (UTC)

@github-actions github-actions bot added the core Refers to `@auth/core` label Jul 2, 2022
Copy link
Member

@ThangHuuVu ThangHuuVu left a comment

Choose a reason for hiding this comment

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

Lgtm

Copy link
Member

@ThangHuuVu ThangHuuVu left a comment

Choose a reason for hiding this comment

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

I missed that as well 🙈

@ndom91 ndom91 changed the title feat: show experimental api warning only in dev and only once fix: show experimental api warning only in dev and only once Jul 2, 2022
Copy link
Collaborator

@ubbe-xyz ubbe-xyz left a comment

Choose a reason for hiding this comment

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

Nice! Small suggestion for readability 💬

packages/next-auth/src/next/index.ts Outdated Show resolved Hide resolved
packages/next-auth/src/next/index.ts Outdated Show resolved Hide resolved
ndom91 and others added 2 commits July 2, 2022 14:02
Co-authored-by: Lluis Agusti <hi@llu.lu>
Co-authored-by: Lluis Agusti <hi@llu.lu>
@ndom91
Copy link
Member Author

ndom91 commented Jul 2, 2022

WIP: Adding a test

Copy link
Collaborator

@ubbe-xyz ubbe-xyz left a comment

Choose a reason for hiding this comment

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

Super 💯

Copy link
Member

@ThangHuuVu ThangHuuVu left a comment

Choose a reason for hiding this comment

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

✅ Lgtm

@ndom91 ndom91 merged commit 993c0f4 into main Jul 2, 2022
@ndom91 ndom91 deleted the ndom91/experimental-api-warning-dev-only branch July 2, 2022 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Refers to `@auth/core`
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants