Skip to content

Commit

Permalink
Fix invalid v-permission:or check
Browse files Browse the repository at this point in the history
The check expects an array of permissions (denoted with `[]`), but was passed a value enclosed in parentheses instead, which has entirely different semantics (https://stackoverflow.com/a/6949229).

This caused the Vulnerability Policies table to not be displayed, unless the user had the `POLICY_MANAGEMENT_DELETE` permission.

Signed-off-by: nscuro <[email protected]>
  • Loading branch information
nscuro committed Sep 26, 2024
1 parent c93d1c8 commit 8703b1c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/views/policy/VulnerabilityPolicyList.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<template>
<div
class="animated fadeIn"
v-permission:or="
('POLICY_MANAGEMENT',
v-permission:or="[
'POLICY_MANAGEMENT',
'POLICY_MANAGEMENT_CREATE',
'POLICY_MANAGEMENT_READ',
'POLICY_MANAGEMENT_UPDATE',
'POLICY_MANAGEMENT_DELETE')
"
'POLICY_MANAGEMENT_DELETE',
]"
>
<b-alert
v-if="bundleSyncStatus === 'FAILED'"
Expand Down

0 comments on commit 8703b1c

Please sign in to comment.