Add a specific error when inviting a remote cluster to a remote channel (#28255)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
c27d536ad3
Коммит
8a735f1b03
@@ -150,7 +150,7 @@ func (scs *Service) InviteRemoteToChannel(channelID, remoteID, userID string, sh
|
||||
// (also blocks cyclic invitations)
|
||||
if err = scs.CheckCanInviteToSharedChannel(channelID); err != nil {
|
||||
if errors.Is(err, model.ErrChannelHomedOnRemote) {
|
||||
return model.NewAppError("InviteRemoteToChannel", "api.command_share.channel_invite_not_home.error", nil, "", http.StatusInternalServerError)
|
||||
return model.NewAppError("InviteRemoteToChannel", "api.command_share.channel_invite_not_home.error", nil, "", http.StatusBadRequest)
|
||||
}
|
||||
scs.server.Log().Debug("InviteRemoteToChannel failed to check if can-invite",
|
||||
mlog.String("name", rc.Name),
|
||||
|
||||
Ссылка в новой задаче
Block a user