MM-35125 CRT: Mention badge on threads doesn't appear until refresh (#17504)

Этот коммит содержится в:
Eli Yukelzon
2021-04-27 10:18:20 +03:00
коммит произвёл GitHub
родитель cd4d322e4a
Коммит ba302cf512
7 изменённых файлов: 99 добавлений и 5 удалений

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

@@ -7926,6 +7926,22 @@ func (s *TimerLayerThreadStore) GetPosts(threadID string, since int64) ([]*model
return result, err
}
func (s *TimerLayerThreadStore) GetThreadFollowers(threadID string) ([]string, error) {
start := timemodule.Now()
result, err := s.ThreadStore.GetThreadFollowers(threadID)
elapsed := float64(timemodule.Since(start)) / float64(timemodule.Second)
if s.Root.Metrics != nil {
success := "false"
if err == nil {
success = "true"
}
s.Root.Metrics.ObserveStoreMethodDuration("ThreadStore.GetThreadFollowers", success, elapsed)
}
return result, err
}
func (s *TimerLayerThreadStore) GetThreadForUser(userID string, teamID string, threadId string, extended bool) (*model.ThreadResponse, error) {
start := timemodule.Now()