[PLT-5170] Add join the channel system message for the person who created the channel (#7299)

* add join the channel system message for the person who created the channel

* update test
Этот коммит содержится в:
Saturnino Abril
2017-08-31 04:29:32 +08:00
коммит произвёл Joram Wilander
родитель bb2ca558bb
Коммит f34cd567a6
5 изменённых файлов: 46 добавлений и 12 удалений

Просмотреть файл

@@ -126,6 +126,13 @@ func CreateChannelWithUser(channel *model.Channel, userId string) (*model.Channe
return nil, err
}
var user *model.User
if user, err = GetUser(userId); err != nil {
return nil, err
}
postJoinChannelMessage(user, channel)
message := model.NewWebSocketEvent(model.WEBSOCKET_EVENT_CHANNEL_CREATED, "", "", userId, nil)
message.Add("channel_id", channel.Id)
message.Add("team_id", channel.TeamId)