MM-18463 Added update_badge notification when marking a channel as unread (#12499)

* MM-18463 Added update_badge notification when marking a channel as unread

* Address feedback
Этот коммит содержится в:
Harrison Healey
2019-10-07 09:58:39 -04:00
коммит произвёл GitHub
родитель 3fa26bd0ee
Коммит 66da2bab2b
9 изменённых файлов: 92 добавлений и 78 удалений

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

@@ -1129,7 +1129,7 @@ func (us SqlUserStore) AnalyticsActiveCount(timePeriod int64, options model.User
return v, nil
}
func (us SqlUserStore) GetUnreadCount(userId string) (int64, error) {
func (us SqlUserStore) GetUnreadCount(userId string) (int64, *model.AppError) {
query := `
SELECT SUM(CASE WHEN c.Type = 'D' THEN (c.TotalMsgCount - cm.MsgCount) ELSE cm.MentionCount END)
FROM Channels c