[**Documentation**](../../../README)

***

[Documentation](../../../README) / [@zerotal/tenancy](../README) / tenantDisk

# Function: tenantDisk()

> **tenantDisk**(`disk?`, `storageManager?`): `StorageDriver`

Defined in: [tenancy/src/tenantStorage.ts:46](https://github.com/zerotaldev/zerotal/blob/1d6fb26b05b18ba077de1bfaeb46c42131cd8b70/packages/tenancy/src/tenantStorage.ts#L46)

Return a proxy over the named storage disk that prefixes every path with
`tenants/<slug>/` for the currently active tenant.

## Parameters

### disk?

`string`

The disk name passed to `Storage.disk()`. Defaults to the default disk.

### storageManager?

`StorageManagerLike`

Optional — pass the `StorageManager` instance directly (useful
  in tests or when the facade isn't available).  When omitted the global `Storage`
  facade is resolved dynamically at call time.

## Returns

`StorageDriver`
