summaryrefslogtreecommitdiffstats
path: root/api/channel.go
diff options
context:
space:
mode:
Diffstat (limited to 'api/channel.go')
-rw-r--r--api/channel.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/api/channel.go b/api/channel.go
index 7222ba0b1..87fbf5d39 100644
--- a/api/channel.go
+++ b/api/channel.go
@@ -649,7 +649,9 @@ func addMember(c *Context, w http.ResponseWriter, r *http.Request) {
return
}
- go c.App.PostAddToChannelMessage(oUser, nUser, channel)
+ c.App.Go(func() {
+ c.App.PostAddToChannelMessage(oUser, nUser, channel)
+ })
c.App.UpdateChannelLastViewedAt([]string{id}, oUser.Id)
w.Write([]byte(cm.ToJson()))