[MM-15122] Migrate "WebHook.GetIncomingByTeam" to Sync by default (#10631)

Этот коммит содержится в:
Siyuan Liu
2019-04-22 08:29:55 -07:00
коммит произвёл Jesse Hallam
родитель 1e92646646
Коммит 434f343f69
6 изменённых файлов: 35 добавлений и 26 удалений

Просмотреть файл

@@ -388,11 +388,7 @@ func (a *App) GetIncomingWebhooksForTeamPage(teamId string, page, perPage int) (
return nil, model.NewAppError("GetIncomingWebhooksForTeamPage", "api.incoming_webhook.disabled.app_error", nil, "", http.StatusNotImplemented)
}
if result := <-a.Srv.Store.Webhook().GetIncomingByTeam(teamId, page*perPage, perPage); result.Err != nil {
return nil, result.Err
} else {
return result.Data.([]*model.IncomingWebhook), nil
}
return a.Srv.Store.Webhook().GetIncomingByTeam(teamId, page*perPage, perPage)
}
func (a *App) GetIncomingWebhooksPage(page, perPage int) ([]*model.IncomingWebhook, *model.AppError) {