v0.2.0
- Added integration with Discord Webhooks - Added daily report summaries - Other fixes and improvements
This commit is contained in:
1 parent
da212951a6
commit
d9ad94e579
10 files changed
+174
-32
No files matched your search
@@ -1,3 +1,5 @@
|
||||
const discordWebhooks = require('../services/discord.js');
|
||||
|
||||
const levels = {
|
||||
0: { method: 'log', label: '[INFO]' },
|
||||
1: { method: 'warn', label: '[WARN]' },
|
||||
@@ -7,4 +9,6 @@ const levels = {
|
||||
module.exports = (level, msg) => {
|
||||
const { method, label } = levels[level] || { method: 'log', label: '[N/A]' };
|
||||
console[method](`${label} ${msg}`);
|
||||
|
||||
if (level >= 1) discordWebhooks(level, msg).catch(console.error);
|
||||
};
|
||||
Reference in new issue
Block a user