Business fixes

This commit is contained in:
Isaac
2024-02-28 19:22:43 +04:00
parent cbb9d42744
commit 8446fd3ab1
35 changed files with 448 additions and 171 deletions

View File

@@ -243,8 +243,11 @@ private func updatedContextQueryResultStateForQuery(context: AccountContext, pee
return false
}
var sortedCommands = filteredCommands.map(ChatInputTextCommand.command)
for shortcut in shortcuts {
sortedCommands.append(.shortcut(shortcut))
if !shortcuts.isEmpty {
sortedCommands.removeAll()
for shortcut in shortcuts {
sortedCommands.append(.shortcut(shortcut))
}
}
return { _ in return .commands(ChatInputQueryCommandsResult(
commands: sortedCommands,