fix: redirect to nopermission screen
This commit is contained in:
parent
9cf2cf2d80
commit
196a92325a
1 changed files with 1 additions and 1 deletions
|
@ -73,7 +73,7 @@ export async function isAuthenticatedPromise(forceRefresh: boolean = false): Pro
|
|||
|
||||
var { userId, firstname, lastname, mail, username, permissions, isOwner } = decoded;
|
||||
|
||||
if (Object.keys(permissions ?? {}).length === 0 && !isOwner) {
|
||||
if (Object.keys(permissions ?? {}).filter((p) => p != "adminByOwner").length === 0 && !isOwner) {
|
||||
auth.setFailed();
|
||||
reject("nopermissions");
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue