Migrate Channel.RemoveAllDeactivatedMembers to Sync by default (#11270)

* Migrate Channel.RemoveAllDeactivatedMembers to Sync by default

* Indent query string
Этот коммит содержится в:
Shobhit Gupta
2019-06-18 14:09:15 -07:00
коммит произвёл Jesús Espino
родитель 6555bea117
Коммит e92ecf6696
5 изменённых файлов: 30 добавлений и 31 удалений

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

@@ -1956,8 +1956,8 @@ func (a *App) PermanentDeleteChannel(channel *model.Channel) *model.AppError {
// is in progress, and therefore should not be used from the API without first fixing this potential race condition.
func (a *App) MoveChannel(team *model.Team, channel *model.Channel, user *model.User, removeDeactivatedMembers bool) *model.AppError {
if removeDeactivatedMembers {
if result := <-a.Srv.Store.Channel().RemoveAllDeactivatedMembers(channel.Id); result.Err != nil {
return result.Err
if err := a.Srv.Store.Channel().RemoveAllDeactivatedMembers(channel.Id); err != nil {
return err
}
}