From c9a0030551f289241407743fbd21080cd8a358a4 Mon Sep 17 00:00:00 2001 From: hmhealey Date: Wed, 30 Sep 2015 12:28:28 -0400 Subject: Moved ChannelMember.NotifyLevel into ChannelMember.NotifyProps --- store/sql_channel_store.go | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) (limited to 'store/sql_channel_store.go') diff --git a/store/sql_channel_store.go b/store/sql_channel_store.go index f453c3589..3bbe7e716 100644 --- a/store/sql_channel_store.go +++ b/store/sql_channel_store.go @@ -78,8 +78,7 @@ func (s SqlChannelStore) UpgradeSchemaIfNeeded() { l4g.Error(err.Error()) } - // TODO uncomment me - // s.RemoveColumnIfExists("ChannelMembers", "NotifyLevel") + s.RemoveColumnIfExists("ChannelMembers", "NotifyLevel") } } @@ -721,36 +720,6 @@ func (s SqlChannelStore) IncrementMentionCount(channelId string, userId string) return storeChannel } -// TODO remove me -func (s SqlChannelStore) UpdateNotifyLevel(channelId, userId, notifyLevel string) StoreChannel { - storeChannel := make(StoreChannel) - - go func() { - result := StoreResult{} - - updateAt := model.GetMillis() - - _, err := s.GetMaster().Exec( - `UPDATE - ChannelMembers - SET - NotifyLevel = :NotifyLevel, - LastUpdateAt = :LastUpdateAt - WHERE - UserId = :UserId - AND ChannelId = :ChannelId`, - map[string]interface{}{"ChannelId": channelId, "UserId": userId, "NotifyLevel": notifyLevel, "LastUpdateAt": updateAt}) - if err != nil { - result.Err = model.NewAppError("SqlChannelStore.UpdateNotifyLevel", "We couldn't update the notify level", "channel_id="+channelId+", user_id="+userId+", "+err.Error()) - } - - storeChannel <- result - close(storeChannel) - }() - - return storeChannel -} - func (s SqlChannelStore) GetForExport(teamId string) StoreChannel { storeChannel := make(StoreChannel) -- cgit v1.2.3-1-g7c22