Changeset 1e532d0

Timestamp:
01/29/26 00:01:37 (4 days ago)
Author:
Vasilaki Tocili <vasilakigorgi@…>
Branches:
nextjs
Children:
f3370b1
Parents:
41ea2cb
Message:

feat: Type end-to-end DB User → Session

Return a safe user from authorize:

  • DB user → sanitized auth user
  • No password leaks
  • Session will only ever see safe fields

Tell NextAuth to persist id into the session:

  • Add callbacks in auth.config.ts

Added JWT in the session typing:

  • DB → Auth → JWT → Session is fully typed
  • session.user.id is safe everywhere
(No files)

Note: See TracChangeset for help on using the changeset viewer.