MM-15289 Migrate command.GetByTeam to sync by default (#10740)
Этот коммит содержится в:
коммит произвёл
Jesús Espino
родитель
214e9d2ae0
Коммит
171058eb3d
@@ -257,12 +257,11 @@ func listCommandCmdF(command *cobra.Command, args []string) error {
|
||||
CommandPrintErrorln("Unable to find team '" + args[i] + "'")
|
||||
continue
|
||||
}
|
||||
result := <-a.Srv.Store.Command().GetByTeam(team.Id)
|
||||
if result.Err != nil {
|
||||
commands, err := a.Srv.Store.Command().GetByTeam(team.Id)
|
||||
if err != nil {
|
||||
CommandPrintErrorln("Unable to list commands for '" + args[i] + "'")
|
||||
continue
|
||||
}
|
||||
commands := result.Data.([]*model.Command)
|
||||
for _, command := range commands {
|
||||
commandListItem := fmt.Sprintf("%s: %s (team: %s)", command.Id, command.DisplayName, team.Name)
|
||||
CommandPrettyPrintln(commandListItem)
|
||||
|
||||
Ссылка в новой задаче
Block a user