import { IContext } from 'degreet-telegram/src/types' bot.on( /action_(.*)/, async (ctx: IContext): Promise<void> => { try { const action: string = ctx.matchParams[1] await ctx.answer.send(action) } catch (e: any) { console.error(e) } } )
bot.on(/action_(.*)/, async (ctx) => { try { const action = ctx.matchParams[1] await ctx.answer.send(action) } catch (e) { console.error(e) } })
Last updated 2 years ago