Thumbnail

rani/matterbridge.git

Clone URL: https://git.buni.party/rani/matterbridge.git

commit 8ee55bde85f5e14f75aceaafbc25093178b76130 Author: Wim <wim@42.be> Date: Sun Sep 10 16:33:29 2017 +0000 Add UpdateUserNick diff --git a/matterclient/matterclient.go b/matterclient/matterclient.go index efd4303..e348b76 100644 --- a/matterclient/matterclient.go +++ b/matterclient/matterclient.go @@ -5746 +57416 @@ func (m *MMClient) UpdateLastViewed(channelId string) {   }  }   +func (m *MMClient) UpdateUserNick(nick string) error { + user := m.User + user.Nickname = nick + _, resp := m.Client.UpdateUser(user) + if resp.Error != nil { + return resp.Error + } + return nil +} +  func (m *MMClient) UsernamesInChannel(channelId string) []string {   res, resp := m.Client.GetChannelMembers(channelId, 0, 50000, "")   if resp.Error != nil {