summaryrefslogtreecommitdiffstats
path: root/api/channel.go
diff options
context:
space:
mode:
authorJoramWilander <jwawilander@gmail.com>2015-08-19 08:31:20 -0400
committerJoramWilander <jwawilander@gmail.com>2015-08-19 08:31:20 -0400
commit11247061b5623140656e3ec0ee96b6566637a950 (patch)
treeed815e8676b3abb436fc77226b485f6f33245002 /api/channel.go
parent7004a348b59d5572e8c84eb1c8138bf45cbd0d3e (diff)
downloadchat-11247061b5623140656e3ec0ee96b6566637a950.tar.gz
chat-11247061b5623140656e3ec0ee96b6566637a950.tar.bz2
chat-11247061b5623140656e3ec0ee96b6566637a950.zip
Track channel creator in DB and show in channel intro message.
Diffstat (limited to 'api/channel.go')
-rw-r--r--api/channel.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/api/channel.go b/api/channel.go
index 151627623..be6a8b064 100644
--- a/api/channel.go
+++ b/api/channel.go
@@ -58,6 +58,8 @@ func createChannel(c *Context, w http.ResponseWriter, r *http.Request) {
return
}
+ channel.CreatorId = c.Session.UserId
+
if sc, err := CreateChannel(c, channel, true); err != nil {
c.Err = err
return