Skip to main content
zerotal

Documentation


Documentation / @zerotal/tenancy / TenantStoragePathError

Class: TenantStoragePathError

Defined in: tenancy/src/errors.ts:77

Raised when a caller-supplied storage key would escape the active tenant's directory.

tenantDisk() prefixes keys with tenants/<slug>/, but the underlying LocalDriver confines paths to the disk root, not the tenant directory — so a key containing .. resolved to a sibling tenant's folder and passed the driver's own check. Traversal is rejected at the prefixing layer instead.

Extends

Constructors

Constructor

new TenantStoragePathError(path, slug): TenantStoragePathError

Defined in: tenancy/src/errors.ts:78

Parameters

path

string

slug

string

Returns

TenantStoragePathError

Overrides

ZerotalError.constructor

Properties

code

readonly code: string

Defined in: core/src/errors/ZerotalError.ts:18

Inherited from

ZerotalError.code


status

readonly status: number = 500

Defined in: core/src/errors/ZerotalError.ts:19

Inherited from

ZerotalError.status


context?

readonly optional context?: Record<string, unknown>

Defined in: core/src/errors/ZerotalError.ts:20

Inherited from

ZerotalError.context