From 6f48dadbe67470cfb940f48f415e021e71bde62c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Famibelle-Pronzola?= Date: Sat, 22 Jul 2023 13:26:02 +0400 Subject: [PATCH] Move nextauth to app directory --- .../api/auth/[...nextauth]/route.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) rename pages/api/auth/[...nextauth].js => app/api/auth/[...nextauth]/route.js (95%) diff --git a/pages/api/auth/[...nextauth].js b/app/api/auth/[...nextauth]/route.js similarity index 95% rename from pages/api/auth/[...nextauth].js rename to app/api/auth/[...nextauth]/route.js index 10fd85f..0daf1a7 100644 --- a/pages/api/auth/[...nextauth].js +++ b/app/api/auth/[...nextauth]/route.js @@ -77,10 +77,11 @@ const options = { } }, pages: { - signIn: '/soumet', - error: '/soumet' + signIn: '/pwopose', + error: '/pwopose' } } -const Auth = (request, response) => +const handler = (request, response) => NextAuth(request, response, options) -export default Auth + +export {handler as GET, handler as POST}