diff options
author | Jesús Espino <jespinog@gmail.com> | 2018-08-03 17:13:02 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-03 17:13:02 +0200 |
commit | 61f98d92faf82a38041c8e709c4bc36e7792752c (patch) | |
tree | 32632b0c3def990976e189142f4dd064927269e2 /app/channel.go | |
parent | 8cc4f27f7cb17af34951ad4c7a59ca7bad082f61 (diff) | |
download | chat-61f98d92faf82a38041c8e709c4bc36e7792752c.tar.gz chat-61f98d92faf82a38041c8e709c4bc36e7792752c.tar.bz2 chat-61f98d92faf82a38041c8e709c4bc36e7792752c.zip |
MM-11576: Allow to join and add members to archived channels (#9214)
Diffstat (limited to 'app/channel.go')
-rw-r--r-- | app/channel.go | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/app/channel.go b/app/channel.go index 0a89574ac..1e48c3c50 100644 --- a/app/channel.go +++ b/app/channel.go @@ -740,10 +740,6 @@ func (a *App) DeleteChannel(channel *model.Channel, userId string) *model.AppErr } func (a *App) addUserToChannel(user *model.User, channel *model.Channel, teamMember *model.TeamMember) (*model.ChannelMember, *model.AppError) { - if channel.DeleteAt > 0 { - return nil, model.NewAppError("AddUserToChannel", "api.channel.add_user_to_channel.deleted.app_error", nil, "", http.StatusBadRequest) - } - if channel.Type != model.CHANNEL_OPEN && channel.Type != model.CHANNEL_PRIVATE { return nil, model.NewAppError("AddUserToChannel", "api.channel.add_user_to_channel.type.app_error", nil, "", http.StatusBadRequest) } @@ -1178,10 +1174,6 @@ func (a *App) GetChannelUnread(channelId, userId string) (*model.ChannelUnread, } func (a *App) JoinChannel(channel *model.Channel, userId string) *model.AppError { - if channel.DeleteAt > 0 { - return model.NewAppError("JoinChannel", "api.channel.join_channel.already_deleted.app_error", nil, "", http.StatusBadRequest) - } - userChan := a.Srv.Store.User().Get(userId) memberChan := a.Srv.Store.Channel().GetMember(channel.Id, userId) |