Skip to content

Commit

Permalink
Revert "matcher warning fix (#671)"
Browse files Browse the repository at this point in the history
This reverts commit e5571d9.
  • Loading branch information
trixobird committed Nov 14, 2024
1 parent e5571d9 commit 84645a7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions apps/backoffice/src/middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ import { type AJwtPayload } from '@repo/shared-types';
import { env } from './env.mjs';
import { AllRoles, UserStatus } from './graphql/generated/schema-server';

export const config = {
matcher: ['/((?!api|_next/static|_next/image|favicon.ico).*)'],
};

export async function middleware(request: NextRequest): Promise<NextResponse> {
const token = request.cookies.get(TOKEN_KEY)?.value;
const refreshToken = request.cookies.get(REFRESH_TOKEN_KEY)?.value;
Expand Down
4 changes: 4 additions & 0 deletions apps/web/src/middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ const publicPaths = [
'/api/auth/reset-password',
];

export const config = {
matcher: ['/((?!api|_next/static|_next/image|favicon.ico|sitemap.xml|robots.txt).*)'],
};

export async function middleware(request: NextRequest): Promise<NextResponse> {
const token = request.cookies.get(TOKEN_KEY)?.value;
const refreshToken = request.cookies.get(REFRESH_TOKEN_KEY)?.value;
Expand Down

0 comments on commit 84645a7

Please sign in to comment.