Skip to content

Commit

Permalink
refactor: use logical or assignment
Browse files Browse the repository at this point in the history
  • Loading branch information
panva committed Feb 4, 2024
1 parent e306640 commit 8f55588
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/helpers/interaction_policy/prompts/consent.js
Expand Up @@ -77,8 +77,8 @@ export default () => new Prompt(

for (const scope of requestedScopes) {
if (availableScopes.has(scope) && !encounteredScopes.has(scope)) {
missing || (missing = {});
missing[indicator] || (missing[indicator] = []);
missing ||= {};
missing[indicator] ||= [];
missing[indicator].push(scope);
}
}
Expand Down

0 comments on commit 8f55588

Please sign in to comment.