From ab25216c1fe9aebfc5a32dc36621b370d7a7c006 Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Thu, 18 Aug 2022 16:31:48 +0200 Subject: [PATCH] web/flows: simplify consent's permission handling Signed-off-by: Jens Langhammer --- web/src/flows/stages/consent/ConsentStage.ts | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/web/src/flows/stages/consent/ConsentStage.ts b/web/src/flows/stages/consent/ConsentStage.ts index 518b71245..2739daafa 100644 --- a/web/src/flows/stages/consent/ConsentStage.ts +++ b/web/src/flows/stages/consent/ConsentStage.ts @@ -37,13 +37,15 @@ export class ConsentStage extends BaseStage perm.name === "").length === perms.length; return html`${perms.map((permission) => { - let name = permission.name; - if (permission.name === "" && shouldShowId) { - name = permission.id; + if (permission.name === "") { + return html``; } - return html`
  • ${name}
  • `; + // Special case for openid Scope + if (permission.id === "openid") { + return html``; + } + return html`
  • ${permission.name}
  • `; })}`; }