"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.catchAsync = function (controller) {
    return function (req, res, next) {
        return controller(req, res, next).catch(function (e) { return next(e); });
    };
};
