11 lines
191 B
TypeScript
11 lines
191 B
TypeScript
const granted = new Set([
|
|
'employee.view',
|
|
'employee.edit',
|
|
'contract.create',
|
|
])
|
|
|
|
export function __can__(...path: string[]) {
|
|
const key = path.join('.')
|
|
return granted.has(key)
|
|
}
|