Balázs Orbán
7e91d7df54
refactor(core): use standard Request and Response ( #4769 )
...
* WIP use `Request` and `Response` for core
* bump Next.js
* rename ts types
* refactor
* simplify
* upgrade Next.js
* implement body reader
* use `Request`/`Response` in `next-auth/next`
* make linter happy
* revert
* fix tests
* remove workaround for middleware return type
* return session in protected api route example
* don't export internal handler
* fall back host to localhost
* refactor `getBody`
* refactor `next-auth/next`
* chore: add `@edge-runtime/jest-environment`
* fix tests, using Node 18 as runtime
* fix test
* remove patch
* fix neo4j build
* remove new-line
* reduce file changes in the PR
* fix tests
* fix tests
* refactor
* refactor
* add host tests
* refactor tests
* fix body reading
* fix tests
* use 302
* fix test
* fix again
* fix tests
* handle when body is `Buffer`
* move comment
2022-12-03 13:39:08 +00:00
Balázs Orbán
6deccf610f
fix(core): return JSON for non-HTML server route errors ( #5442 )
...
* fix(core): return JSON for non-HTML server route errors
* refactor: throw in `unstable_getServerSession`
* test: expect `unstable_getServerSession` to throw
* refactor: destructure
* fix unrelated test formatting
* catch error page
2022-09-28 17:01:39 +01:00
Balázs Orbán
8104cb1287
chore: fix builds/tests/eslint ( #4780 )
...
* chore(deps): upgrade `typescript`
* chore(ts): don't exclude test files in tsconfig
* test: expect error when overriding `NODE_ENV`
* chore: remove unused import
* format
* chore: use pnpm@7 in action
* chore: fix eslint
* chore: remove pnpm from engines
* chore: fix configs/builds
* fix: make eslint works
* Update pnpm-lock.yaml
* fix: build failure
* fix: add react to paths
* ignore upstash for now
* add eslintignore, add a bunch of tsconfig.eslint.json
* ignore mikro orm for now
* Delete tsconfig.eslint.json
* Update package.json
* Update pnpm-lock.yaml
* move eslint back to package.json
* move eslintrc.js out
Co-authored-by: Thang Vu <thvu@hey.com >
Co-authored-by: Thang Vu <thang.vu@binance.com >
2022-09-09 13:51:40 +02:00
Melanie Seltzer
a82cbf5ddf
fix: return null in unstable_getServerSession if there's an error ( #5218 )
...
* fix: return null in unstable_getServerSession if there's an error
* Remove status check and instead check body is not a string
* Combine similar tests
2022-08-31 09:19:14 +07:00
Balázs Orbán
afb1fcdae3
fix(providers): add normalizeIdentifier to EmailProvider
...
* fix(providers): add `normalizeIdentifier` to EmailProvider
* docs: document `normalizeIdentifier`
* fix: allow throwing error from normalizer
* test: add e-mail tests
* chore: log provider id
* test: merge client+config jest configs and add coverage report
* test: show coverage for untested files
* fix: only allow first domain in email. Add tests
* chore: add `coverage` to tsconfig exclude list
* cleanup
* revert
Co-authored-by: Thang Vu <thvu@hey.com >
2022-08-01 13:43:19 +02:00
Nico Domino
993c0f46b0
fix: show experimental api warning only in dev and only once ( #4816 )
...
Co-authored-by: Lluis Agusti <hi@llu.lu >
2022-07-02 21:00:11 +02:00
Balázs Orbán
c194261617
fix(core): respect NEXTAUTH_SECRET in unstable_getServerSession ( #4774 )
...
* fix(core): respect `NEXTAUTH_SECRET` in `unstable_getServerSession`
* add `secret` tests
* add `@types/jest`
* fix tests
2022-06-27 17:00:08 +02:00