web/user: fix ak-user-settings-password getting wrong configureUrl

closes #1733

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2021-11-04 13:50:26 +01:00
parent b362d2af03
commit 5000c5b061
1 changed files with 6 additions and 7 deletions

View File

@ -90,14 +90,13 @@ export class UserSettingsPage extends LitElement {
<div class="pf-l-stack__item">
${until(
this.userSettings?.then((settings) => {
if (
settings.filter(
(stage) =>
stage.component === "ak-user-settings-password",
).length > 0
) {
const pwStage = settings.filter(
(stage) =>
stage.component === "ak-user-settings-password",
);
if (pwStage.length > 0) {
return html`<ak-user-settings-password
configureUrl=${ifDefined(settings[0].configureUrl)}
configureUrl=${ifDefined(pwStage[0].configureUrl)}
></ak-user-settings-password>`;
}
}),