Skip to content

fix(docs): remove deprecated usage from drizzle adaptor sample code #13099

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mst-mkt
Copy link

@mst-mkt mst-mkt commented Jul 8, 2025

☕️ Reasoning

Fixed deprecated usage in the schema example of the Drizzle adapter documentation. - The method used was deprecated in drizzle-orm v0.36.0 (current version: v0.44.2). Drizzle ORM documentation now reflects the updated approach.

In that drizzle-orm update, there was a change in how the third argument is passed when defining indexes, composite primary keys, and similar constraints, as shown below.

  sqliteTable('users', {
      id: integer().primaryKey(),
- }, (t) => ({
-     index: index('test').on(t.id),
- }));
+ }, (t) => [
+     index('test').on(t.id)
+ ])

Also, #12285 addresses a similar update related to the drizzle-orm version, but in a different part of the documentation. It might be helpful to incorporate both changes.

🧢 Checklist

  • Documentation
  • Tests
  • Ready to be merged

🎫 Affected issues

📌 Resources

@mst-mkt mst-mkt requested a review from ndom91 as a code owner July 8, 2025 08:58
Copy link

vercel bot commented Jul 8, 2025

@mst-mkt is attempting to deploy a commit to the authjs Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

vercel bot commented Jul 8, 2025

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

Name Status Preview Comments Updated (UTC)
auth-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 8, 2025 9:02am
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
next-auth-docs ⬜️ Ignored (Inspect) Jul 8, 2025 9:02am

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