From 8be107cecc9ed68c7f97ec7561b2a7eeee9ce791 Mon Sep 17 00:00:00 2001 From: Wim Date: Fri, 9 Feb 2018 00:11:20 +0100 Subject: [PATCH] Fix mattermost API change --- matterclient/matterclient.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/matterclient/matterclient.go b/matterclient/matterclient.go index e43fd223..8d9f6a37 100644 --- a/matterclient/matterclient.go +++ b/matterclient/matterclient.go @@ -585,9 +585,9 @@ func (m *MMClient) UpdateChannelHeader(channelId string, header string) { func (m *MMClient) UpdateLastViewed(channelId string) { m.log.Debugf("posting lastview %#v", channelId) view := &model.ChannelView{ChannelId: channelId} - res, _ := m.Client.ViewChannel(m.User.Id, view) - if !res { - m.log.Errorf("ChannelView update for %s failed", channelId) + _, resp := m.Client.ViewChannel(m.User.Id, view) + if resp.Error != nil { + m.log.Errorf("ChannelView update for %s failed: %s", channelId, resp.Error) } }