Compare commits
No commits in common. "b2c22dc5a536146e9f3f85a856b450edda85cce4" and "2e0ff4ae6ff089da81805113b4de46150c9f9756" have entirely different histories.
b2c22dc5a5
...
2e0ff4ae6f
@ -22,5 +22,5 @@ export async function middleware(request: NextRequest) {
|
||||
// 2. /admin/* (exclude all routes under /admin)
|
||||
// 3. /_next/* (exclude Next.js static and image assets)
|
||||
export const config = {
|
||||
matcher: ['/((?!login|assets).*)', '/((?!_next/static|_next/image|favicon.ico).*)'],
|
||||
matcher: ['/((?!dashboard|login|admin|api|_next/static|_next/image|favicon.ico).*)'],
|
||||
}
|
||||
|
||||
@ -74,12 +74,6 @@ export default function EdgeProvider({ children, sessionData }: EdgeProviderProp
|
||||
router.push('/')
|
||||
}
|
||||
}
|
||||
|
||||
if (pathname === '/') {
|
||||
if (!session?.isLoggedIn) {
|
||||
router.push('/login')
|
||||
}
|
||||
}
|
||||
//alert 함수 변경해서 바인딩
|
||||
window.alert = function (msg, alertBtn = () => setAlert(false)) {
|
||||
alertFunc(msg, alertBtn)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user