This commit is contained in:
andres
2023-03-14 02:31:40 +01:00
parent 7815284efb
commit dab1b72702

View File

@@ -116,10 +116,10 @@ const scrape = async () => {
await browser?.close?.()
}
}
const cronTask = cron.schedule('*/1 * * * *', async () => {
const cronTask = cron.schedule('*/1 9-17 * * *', async () => {
await scrape()
})
console.log('valid: ', cron.validate('*/1 * * * *'))
console.log('valid: ', cron.validate('*/1 9-17 * * *'))
bot.on(message('text'), async (ctx) => {
const text = ctx.message?.text
if (ctx.message.from.id !== Number(process.env.MY_TELEGRAM_ID)) return