Fix channel created WS event (#5552)
Этот коммит содержится в:
@@ -107,6 +107,7 @@ func CreateChannelWithUser(channel *model.Channel, userId string) (*model.Channe
|
||||
|
||||
message := model.NewWebSocketEvent(model.WEBSOCKET_EVENT_CHANNEL_CREATED, "", "", userId, nil)
|
||||
message.Add("channel_id", channel.Id)
|
||||
message.Add("team_id", channel.TeamId)
|
||||
Publish(message)
|
||||
|
||||
return rchannel, nil
|
||||
|
||||
@@ -286,8 +286,9 @@ function handleUserUpdatedEvent(msg) {
|
||||
|
||||
function handleChannelCreatedEvent(msg) {
|
||||
const channelId = msg.data.channel_id;
|
||||
const teamId = msg.data.team_id;
|
||||
|
||||
if (!ChannelStore.getChannelById(channelId)) {
|
||||
if (TeamStore.getCurrentId() === teamId && !ChannelStore.getChannelById(channelId)) {
|
||||
AsyncClient.getChannel(channelId);
|
||||
}
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user