refactor: standardize code formatting and improve consistency across various components and API routes for enhanced readability and maintainability

This commit is contained in:
Julien Froidefond
2025-12-10 14:28:05 +01:00
parent 299a66e6ff
commit f8919b19b3
19 changed files with 152 additions and 161 deletions

View File

@@ -23,7 +23,7 @@ export async function POST(request: Request) {
console.error("Error creating folder:", error);
return NextResponse.json(
{ error: "Failed to create folder" },
{ status: 500 }
{ status: 500 },
);
}
}
@@ -48,7 +48,7 @@ export async function PUT(request: Request) {
console.error("Error updating folder:", error);
return NextResponse.json(
{ error: "Failed to update folder" },
{ status: 500 }
{ status: 500 },
);
}
}
@@ -64,7 +64,7 @@ export async function DELETE(request: Request) {
if (!id) {
return NextResponse.json(
{ error: "Folder ID is required" },
{ status: 400 }
{ status: 400 },
);
}
@@ -79,7 +79,7 @@ export async function DELETE(request: Request) {
headers: {
"Cache-Control": "no-store",
},
}
},
);
} catch (error) {
if (error instanceof FolderNotFoundError) {
@@ -88,7 +88,7 @@ export async function DELETE(request: Request) {
console.error("Error deleting folder:", error);
return NextResponse.json(
{ error: "Failed to delete folder" },
{ status: 500 }
{ status: 500 },
);
}
}