feat(editor): Replace middleware for Role checks with Scope checks (#7847)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { defineStore } from 'pinia';
|
||||
import { hasScope as genericHasScope } from '@n8n/permissions';
|
||||
import type { HasScopeOptions, Scope, Resource } from '@n8n/permissions';
|
||||
import type { ScopeOptions, Scope, Resource } from '@n8n/permissions';
|
||||
import { ref } from 'vue';
|
||||
import { STORES } from '@/constants';
|
||||
import type { IRole } from '@/Interface';
|
||||
@@ -80,7 +80,7 @@ export const useRBACStore = defineStore(STORES.RBAC, () => {
|
||||
resourceId?: string;
|
||||
projectId?: string;
|
||||
},
|
||||
options?: HasScopeOptions,
|
||||
options?: ScopeOptions,
|
||||
): boolean {
|
||||
return genericHasScope(
|
||||
scope,
|
||||
|
||||
Reference in New Issue
Block a user