refactor: remove error-silencing try/catch on event handler imports (#5542)

This commit is contained in:
Robert Coe
2021-04-30 12:48:19 -07:00
committed by GitHub
parent 5397021efb
commit cdcc50f365

View File

@@ -5,9 +5,7 @@ const { WSEvents } = require('../../../util/Constants');
const handlers = {}; const handlers = {};
for (const name of Object.keys(WSEvents)) { for (const name of Object.keys(WSEvents)) {
try { handlers[name] = require(`./${name}.js`);
handlers[name] = require(`./${name}.js`);
} catch {} // eslint-disable-line no-empty
} }
module.exports = handlers; module.exports = handlers;