"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.handleErrorResponse = exports.handleHttpError = void 0;
const handleHttpError = (res, error) => {
    res.status(500);
    res.send({ error: "ERROR", message: error });
};
exports.handleHttpError = handleHttpError;
const handleErrorResponse = (res, message = "Algo ocurrio", code = 401) => {
    res.status(code);
    res.send({ error: message });
};
exports.handleErrorResponse = handleErrorResponse;
