fix: must have length or will fail
This commit is contained in:
parent
23e072986d
commit
8fbeda892b
1 changed files with 1 additions and 0 deletions
|
|
@ -57,6 +57,7 @@ export async function expressAuthentication(
|
||||||
|
|
||||||
if (
|
if (
|
||||||
scopes &&
|
scopes &&
|
||||||
|
scopes.length > 0 &&
|
||||||
scopes
|
scopes
|
||||||
.map((v) => (v === "management-role" ? process.env.MANAGEMENT_ROLE : v))
|
.map((v) => (v === "management-role" ? process.env.MANAGEMENT_ROLE : v))
|
||||||
.every((v) => !payload.resource_access[payload.azp].roles.includes(v))
|
.every((v) => !payload.resource_access[payload.azp].roles.includes(v))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue