Skip to content

basalt / permissions/src / InvalidCanMetaError

Class: InvalidCanMetaError ​

Defined in: permissions/src/errors.ts:24

A route declared meta.can with a shape the guard cannot enforce (anything other than a non-empty string or a non-empty array of strings). Thrown on every request to that route: an unenforceable authorization declaration must fail CLOSED, never silently skip the permission check.

Extends ​

Constructors ​

Constructor ​

> new InvalidCanMetaError(route, received): InvalidCanMetaError

Defined in: permissions/src/errors.ts:26

Parameters ​

route ​

string

received ​

unknown

Returns ​

InvalidCanMetaError

Overrides ​

BasaltError.constructor

Properties ​

code ​

> readonly code: string

Defined in: core/src/errors.ts:25

Inherited from ​

BasaltError.code


details? ​

> readonly optional details?: Record<string, unknown>

Defined in: core/src/errors.ts:28

Structured payload passed to the constructor, exactly as given (never sanitised here).

Inherited from ​

BasaltError.details


status ​

> readonly status: 500 = 500

Defined in: permissions/src/errors.ts:25

Released under the MIT License.