484f4724f4
Moving tests to reduce app-dir/app/index.test.ts running duration
12 lines
349 B
JavaScript
12 lines
349 B
JavaScript
// @ts-check
|
|
import { NextResponse } from 'next/server'
|
|
|
|
/**
|
|
* @param {import('next/server').NextRequest} request
|
|
* @returns {NextResponse | undefined}
|
|
*/
|
|
export function middleware(request) {
|
|
if (request.nextUrl.pathname === '/redirect-middleware-to-dashboard') {
|
|
return NextResponse.redirect(new URL('/redirect-dest', request.url))
|
|
}
|
|
}
|