MM-60980: Add RemoteClusterInvite.IsValid (#28624)
Co-authored-by: Mattermost Build <build@mattermost.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
73fc99b577
Коммит
e6d6881917
@@ -204,6 +204,10 @@ func (a *App) CreateRemoteClusterInvite(remoteId, siteURL, token, password strin
|
||||
Token: token,
|
||||
}
|
||||
|
||||
if err := invite.IsValid(); err != nil {
|
||||
return "", model.NewAppError("CreateRemoteClusterInvite", "api.remote_cluster.create_invite_error", nil, "", http.StatusInternalServerError).Wrap(err)
|
||||
}
|
||||
|
||||
encrypted, err := invite.Encrypt(password)
|
||||
if err != nil {
|
||||
return "", model.NewAppError("CreateRemoteClusterInvite", "api.remote_cluster.encrypt_invite_error", nil, "", http.StatusInternalServerError).Wrap(err)
|
||||
|
||||
Ссылка в новой задаче
Block a user