From 16a970b8fb9183165208a83e6f068f3e61e94f4e Mon Sep 17 00:00:00 2001 From: srgooglo Date: Fri, 18 Feb 2022 13:03:44 +0100 Subject: [PATCH] remove unused class --- src/classes/Controller/index.js | 19 ------------------- 1 file changed, 19 deletions(-) delete mode 100755 src/classes/Controller/index.js diff --git a/src/classes/Controller/index.js b/src/classes/Controller/index.js deleted file mode 100755 index 6969599..0000000 --- a/src/classes/Controller/index.js +++ /dev/null @@ -1,19 +0,0 @@ -class Controller { - constructor(payload) { - this.payload = {...payload} - - return this - } - - exec = async (req, res, next) => { - if (typeof this.payload.exec === "function") { - try { - await this.payload.exec (req, res, next) - } catch (error) { - return res.status(500).json({ error: error.message, endpoint: this.payload.route }) - } - } - } -} - -module.exports = { Controller } \ No newline at end of file