@live-change/access-control-service
Advanced tools
Comparing version 0.8.75 to 0.8.76
@@ -14,3 +14,3 @@ import { parents, parentsSources } from './accessControlParents.js' | ||
hasAny = (roles, client, { objectType, object }) => roles.length > 0, | ||
isAdmin = (roles, client, { objectType, object }) => roles.includes('administrator'), | ||
isAdmin = (roles, client, { objectType, object }) => roles.includes('admin'), | ||
canInvite = (roles, client, { objectType, object }) => roles.length > 0, | ||
@@ -17,0 +17,0 @@ canRequest = (roles, client, { objectType, object }) => false |
@@ -228,3 +228,3 @@ import App from '@live-change/framework' | ||
const myRoles = await access.getClientObjectRoles(client, { objectType, object }, true) | ||
if(!myRoles.includes('administrator')) { | ||
if(!myRoles.includes('admin')) { | ||
for(const requestedRole of roles) { | ||
@@ -231,0 +231,0 @@ if(!myRoles.includes(requestedRole)) throw 'notAuthorized' |
{ | ||
"name": "@live-change/access-control-service", | ||
"version": "0.8.75", | ||
"version": "0.8.76", | ||
"description": "", | ||
@@ -24,6 +24,6 @@ "main": "index.js", | ||
"dependencies": { | ||
"@live-change/framework": "^0.8.75" | ||
"@live-change/framework": "^0.8.76" | ||
}, | ||
"gitHead": "9380bbf47a2a9087840cc71afe5b3eace66fa6ab", | ||
"gitHead": "70c9a5ffb257f57b77754027d9c543584ca3423b", | ||
"type": "module" | ||
} |
@@ -48,3 +48,3 @@ import App from '@live-change/framework' | ||
const myRoles = await access.getClientObjectRoles(client, { objectType, object }, true) | ||
if(!myRoles.includes('administrator')) { | ||
if(!myRoles.includes('admin')) { | ||
for(const requestedRole of roles) { | ||
@@ -51,0 +51,0 @@ if(!myRoles.includes(requestedRole)) throw 'notAuthorized' |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
38442