error handling + file size
This commit is contained in:
@@ -15,6 +15,13 @@ export async function middleware(req: NextRequest) {
|
||||
}
|
||||
|
||||
export const config = {
|
||||
matcher: ["/dashboard/:path*", "/api/files/:path*"],
|
||||
matcher: [
|
||||
"/dashboard/:path*",
|
||||
// Match all /api/files routes EXCEPT /api/files/upload (which handles large bodies)
|
||||
"/api/files/list",
|
||||
"/api/files/delete-all",
|
||||
"/api/files/:id/download",
|
||||
"/api/files/:id/delete",
|
||||
],
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user