style(backend): apply Prettier formatting

This commit is contained in:
SaidSoighiri94
2026-06-16 10:01:20 +02:00
parent d67cf8d65e
commit 57266b5414
3 changed files with 56 additions and 19 deletions
+6 -1
View File
@@ -5,7 +5,12 @@ import { logger } from '../utils/logger';
/* Le 4e argument est requis par Express pour identifier un gestionnaire d'erreurs,
même s'il n'est pas utilisé. */
export function errorHandler(err: unknown, _req: Request, res: Response, _next: NextFunction): void {
export function errorHandler(
err: unknown,
_req: Request,
res: Response,
_next: NextFunction,
): void {
const isAppError = err instanceof AppError;
const statusCode = isAppError ? err.statusCode : 500;
const message = isAppError ? err.message : 'Erreur interne du serveur';
+1 -6
View File
@@ -27,12 +27,7 @@ export const ETAT_CHECKLIST_ELEMENT = ['PRESENT', 'ABSENT', 'DETERIORE'] as cons
export type EtatChecklistElement = (typeof ETAT_CHECKLIST_ELEMENT)[number];
export const STATUT_ANOMALIE = [
'DETECTEE',
'EN_COURS_TRAITEMENT',
'RESOLUE',
'CLOTUREE',
] as const;
export const STATUT_ANOMALIE = ['DETECTEE', 'EN_COURS_TRAITEMENT', 'RESOLUE', 'CLOTUREE'] as const;
export type StatutAnomalie = (typeof STATUT_ANOMALIE)[number];