Skip to content

2.3.0-rc1

Pre-release
Pre-release

Choose a tag to compare

@yagop yagop released this 03 Nov 12:11
· 2 commits to master since this release
e02729c

Dispatch

  • bot.command(name, ...) now ignores commands addressed to another bot: in a
    group, /start@some_bot runs the handler only when @some_bot is this bot's
    own username (compared case-insensitively, as Telegram usernames are);
    /start@other_bot falls through to downstream middleware, and a bare /start
    still always matches. The command name itself stays case-sensitive. To make
    the comparison, the bot learns its own @username via getMe(), called once
    inside bot.init() and kept for the process lifetime (a bot's username is
    permanent, so there is no refresh). The bot's identity is exposed as
    bot.botInfo (User | undefined) and to handlers as ctx.me.

Full diff: v2.3.0-rc0...v2.3.0-rc1