1
0
mirror of https://github.com/bpatrik/pigallery2.git synced 2025-12-05 23:18:43 +02:00

implementing thumbnail settings

This commit is contained in:
Braun Patrik
2017-07-15 12:47:11 +02:00
parent 0781f54c90
commit 998efcdbf5
44 changed files with 611 additions and 292 deletions

View File

@@ -1,5 +1,5 @@
import {RenderingMWs} from "../middlewares/RenderingMWs";
import {Error, ErrorCodes} from "../../common/entities/Error";
import {ErrorCodes, ErrorDTO} from "../../common/entities/Error";
import {Logger} from "../Logger";
import Request = Express.Request;
import Response = Express.Response;
@@ -21,7 +21,7 @@ export class ErrorRouter {
app.use((err: any, req: Request, res: Response, next: Function) => {
//Flush out the stack to the console
Logger.error("Unexpected error:", err);
next(new Error(ErrorCodes.SERVER_ERROR, "Unknown server side error", err));
next(new ErrorDTO(ErrorCodes.SERVER_ERROR, "Unknown server side error", err));
},
RenderingMWs.renderError
);