mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-08-01 17:57:51 +00:00
Replaced int botStatus with a type-safe Data::BotStatus enum class.
This commit is contained in:
@@ -40,8 +40,8 @@ QString WrapCommandInChat(
|
||||
? peer->asChat()->botStatus
|
||||
: peer->isMegagroup()
|
||||
? peer->asChannel()->mgInfo->botStatus
|
||||
: -1;
|
||||
return ((command.indexOf('@') < 2) && (botStatus == 0 || botStatus == 2))
|
||||
: Data::BotStatus::NoBots;
|
||||
return ((command.indexOf('@') < 2) && (botStatus != Data::BotStatus::NoBots))
|
||||
? command + '@' + bot->username()
|
||||
: command;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user