web/user: fix success popup showing after each flow stage

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>

closes #2547

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2022-03-22 20:16:57 +01:00
parent 0bbea79c64
commit a0e29d42a6
1 changed files with 4 additions and 4 deletions

View File

@ -75,10 +75,6 @@ export class UserSettingsFlowExecutor extends LitElement implements StageHost {
flowChallengeResponseRequest: payload,
})
.then((data) => {
showMessage({
level: MessageLevel.success,
message: t`Successfully updated details`,
});
this.challenge = data;
if (this.challenge.responseErrors) {
return false;
@ -194,6 +190,10 @@ export class UserSettingsFlowExecutor extends LitElement implements StageHost {
console.debug("authentik/user/flows: redirect to '/', restarting flow.");
this.firstUpdated();
this.globalRefresh();
showMessage({
level: MessageLevel.success,
message: t`Successfully updated details`,
});
return html``;
case ChallengeChoices.Shell:
return html`${unsafeHTML((this.challenge as ShellChallenge).body)}`;