DefaultFindDispatcherStrategy

constructor(dispatchers: List<StateDispatcher<out State>>, botUsername: String? = null)

Parameters

botUsername

the bot's own @name, without the @. Telegram appends @botname to a command whenever more than one bot can see the chat, and that suffix is the only thing saying which bot was meant. Left null — the default, because telek cannot know the name on its own — a command addressed to any bot is handled, which is right in a private chat and in a group with one bot, and wrong in a group with two: this bot would answer commands meant for the other. Pass the name and a command addressed elsewhere stops being a command here; it reaches the current state's dispatcher as the ordinary message it is, rather than vanishing.