- Bot Telegram ...
This commit is contained in:
@@ -58,6 +58,8 @@ const admin_router = require('./router/admin_router');
|
||||
|
||||
const { MyEvent } = require('./models/myevent');
|
||||
|
||||
const telegrambot = require('./telegram/telegrambot');
|
||||
|
||||
require('./db/mongoose');
|
||||
|
||||
console.log("DB: " + process.env.DATABASE);
|
||||
@@ -137,6 +139,7 @@ if (app.get('env') === 'development') {
|
||||
// error: err
|
||||
// });
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
require('./telegram/telegrambot');
|
||||
@@ -263,4 +266,9 @@ cron.schedule('*/2 * * * *', () => {
|
||||
// console.log(`Server started at port ${port}`);
|
||||
//});
|
||||
|
||||
telegrambot.sendMsgTelegram('7', telegrambot.ADMIN_USER_SERVER, `Ciao ${telegrambot.ADMIN_USER_NAME_SERVER}!`);
|
||||
telegrambot.sendMsgTelegramByIdTelegram('7', telegrambot.ADMIN_IDTELEGRAM_SERVER, `Il Server ${process.env.DATABASE} è appena ripartito!`);
|
||||
|
||||
// telegrambot.sendMsgTelegramToTheManagers('7', 'PROVAAA!');
|
||||
|
||||
module.exports = { app };
|
||||
|
||||
Reference in New Issue
Block a user