update
This commit is contained in:
parent
8c180e9a60
commit
d77fc978a0
4
app.js
4
app.js
@ -62,13 +62,13 @@ bot.on('message', (msg) => {
|
|||||||
|
|
||||||
for (const x of jointArray) {
|
for (const x of jointArray) {
|
||||||
if (msg.text && msg.text.toString() === x.NAME) {
|
if (msg.text && msg.text.toString() === x.NAME) {
|
||||||
common.chat(bot, msg, x.NAME)
|
common.chat(bot, msg, x.NAME, logger)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (const x of commands) {
|
for (const x of commands) {
|
||||||
if (msg.text && msg.text.toString().includes(x.NAME)) {
|
if (msg.text && msg.text.toString().includes(x.NAME)) {
|
||||||
common.commands(bot, msg, x.NAME)
|
common.commands(bot, msg, x.NAME, logger)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@ const decache = require('decache');
|
|||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
commands: async (bot, msg, input) => {
|
commands: async (bot, msg, input) => {
|
||||||
|
logger.info("ID - " + msg.from.id + " First Name - " + msg.from.first_name + " did - " + input);
|
||||||
const userMention = "<a href=\"tg:\/\/user?id=" + msg.from.id + "\">@" + msg.from.first_name + "<\/a> "
|
const userMention = "<a href=\"tg:\/\/user?id=" + msg.from.id + "\">@" + msg.from.first_name + "<\/a> "
|
||||||
let commands = require('../../group/commands')
|
let commands = require('../../group/commands')
|
||||||
for (const x of commands) {
|
for (const x of commands) {
|
||||||
@ -18,6 +19,7 @@ module.exports = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
chat: async (bot, msg, input) => {
|
chat: async (bot, msg, input) => {
|
||||||
|
logger.info("ID - " + msg.from.id + " First Name - " + msg.from.first_name + " asked - " + input);
|
||||||
const userMention = "<a href=\"tg:\/\/user?id=" + msg.from.id + "\">@" + msg.from.first_name + "<\/a> "
|
const userMention = "<a href=\"tg:\/\/user?id=" + msg.from.id + "\">@" + msg.from.first_name + "<\/a> "
|
||||||
let commands = require('../../group/commands')
|
let commands = require('../../group/commands')
|
||||||
let navigation = require('../../group/FAQ')
|
let navigation = require('../../group/FAQ')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user