Skip to content

Commit

Permalink
appease linter
Browse files Browse the repository at this point in the history
  • Loading branch information
David Buckley committed Aug 13, 2019
1 parent 293b111 commit 9d37efc
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions matterclient/channels.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ func (m *MMClient) GetChannelId(name string, teamId string) string { //nolint:go
for _, t := range m.OtherTeams {
for _, channel := range append(t.Channels, t.MoreChannels...) {
if channel.Type == model.CHANNEL_GROUP {
res := strings.Replace(channel.DisplayName, ", ", "-", -1)
res = strings.Replace(res, " ", "_", -1)
res := strings.ReplaceAll(channel.DisplayName, ", ", "-")
res = strings.ReplaceAll(res, " ", "_")
if res == name {
return channel.Id
}
Expand All @@ -64,8 +64,8 @@ func (m *MMClient) getChannelIdTeam(name string, teamId string) string { //nolin
if t.Id == teamId {
for _, channel := range append(t.Channels, t.MoreChannels...) {
if channel.Type == model.CHANNEL_GROUP {
res := strings.Replace(channel.DisplayName, ", ", "-", -1)
res = strings.Replace(res, " ", "_", -1)
res := strings.ReplaceAll(channel.DisplayName, ", ", "-")
res = strings.ReplaceAll(res, " ", "_")
if res == name {
return channel.Id
}
Expand Down

0 comments on commit 9d37efc

Please sign in to comment.