"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.identity = exports.catchAsync = exports.createRouter = void 0;
var express_1 = require("express");
exports.createRouter = function () {
    return express_1.Router({
        caseSensitive: true,
        mergeParams: true,
        strict: true
    });
};
/**
 * Type arguments:
 * - Path params
 * - Response body
 * - Request body
 * - Query params
 */
exports.catchAsync = function (controller) {
    return function (req, res, next) {
        return controller(req, res, next).catch(function (e) { return next(e); });
    };
};
exports.identity = function (req, res, next) {
    console.log('identify');
    next();
};
