access-right
Advanced tools
Comparing version 2.0.2 to 2.0.3
@@ -45,3 +45,3 @@ { | ||
}, | ||
"version": "2.0.2" | ||
"version": "v2.0.3" | ||
} |
@@ -92,2 +92,12 @@ var uut = require('../'); | ||
it('test #2: is Allowed should return true for - in rights', () => { | ||
const has = ['filebrowser.local.read']; | ||
const needs = 'filebrowser.local.read.demo-test'; | ||
const result = uut.isAllowed(has, needs); | ||
expect(result).toBe(true); | ||
}); | ||
it('test #3: work with multiple required rights and subrights', () => { | ||
@@ -94,0 +104,0 @@ const has = ['a.b']; |
@@ -36,3 +36,3 @@ var _CONST = { | ||
right = escapeRegExp(right); | ||
var regExp = new RegExp('^' + right + '(\\.[a-zA-Z0-9_\\.]*)*$'); | ||
var regExp = new RegExp('^' + right + '(\\.[a-zA-Z0-9_\\-\\.]*)*$'); | ||
requires.forEach(function(required) { | ||
@@ -39,0 +39,0 @@ found = found || regExp.test(required); |
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
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
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
9483
131
1