NextAuth middleware redirect error
Unanswered
Crazy ant posted this in #help-forum
Crazy antOP
Hello everyone, I want to redirect authenticated users to profile page "/profile/970fn373cc3f2ef6enb88c1g "
during login , it will use callback url but when user is already logged in then home page should be automatically rediredted to "/profile/970fn373cc3f2ef6enb88c1g "
How do I acheive automatically redirection of home page to profile page when user is already logged in.What code should I write in middleware file to acheive this.
during login , it will use callback url but when user is already logged in then home page should be automatically rediredted to "/profile/970fn373cc3f2ef6enb88c1g "
How do I acheive automatically redirection of home page to profile page when user is already logged in.What code should I write in middleware file to acheive this.