2
0
mirror of https://github.com/thedevs-network/the-guard-bot synced 2025-08-30 05:37:59 +00:00
This commit is contained in:
GingerPlusPlus 2019-03-18 19:05:16 +01:00
parent e4ba6d151a
commit 5bbdb529f1
3 changed files with 9 additions and 0 deletions

View File

@ -0,0 +1,3 @@
'use strict';
module.exports = require('./ban');

View File

@ -10,6 +10,10 @@ const updateUserDataHandler = async (ctx, next) => {
updateUser(ctx.message.forward_from);
}
const { entities = [] } = ctx.message;
await Promise.all(entities.map(({ user }) => user && updateUser(user)));
if (!ctx.from) return next();
const user = await updateUser(ctx.from);

View File

@ -1,5 +1,7 @@
'use strict';
process.chdir(__dirname);
// Utils
const { logError } = require('./utils/log');