Merge pull request #689 from Vechtomov/protected-routes

Add protected routes
This commit is contained in:
Keith Stevens
2023-01-14 07:58:06 +09:00
committed by GitHub
+11 -1
View File
@@ -4,5 +4,15 @@ export { default } from "next-auth/middleware";
* Guards these pages and redirects them to the sign in page.
*/
export const config = {
matcher: ["/create/:path*", "/evaluate/:path*", "/label/:path*", "/account/:path*", "/dashboard", "/admin/:path*"],
matcher: [
"/create/:path*",
"/evaluate/:path*",
"/label/:path*",
"/account/:path*",
"/dashboard",
"/admin/:path*",
"/tasks/:path*",
"/leaderboard",
"/messages/:path*",
],
};