diff --git a/packages/plugin-permissions/src/AccessController.ts b/packages/plugin-permissions/src/AccessController.ts index c35481fdb..372c817fe 100644 --- a/packages/plugin-permissions/src/AccessController.ts +++ b/packages/plugin-permissions/src/AccessController.ts @@ -84,7 +84,7 @@ export type CollectionPermissions = { tabs: any[] }; -export type PermissionParams = true | null | { +export type PermissionParams = boolean | { filter: any, fields: any[] }; @@ -175,7 +175,7 @@ export default class AccessController { const any = await this.any(); - if (!any || any === true) { + if (typeof any === 'boolean') { return any; } @@ -209,7 +209,7 @@ export default class AccessController { @@ -338,12 +338,11 @@ export default class AccessController