mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 21:54:03 +00:00
Change possibleTenantSymlinks not to prefix the paths twice while tenancy is initialized
This commit is contained in:
parent
f61675473a
commit
8e06ae61e6
1 changed files with 3 additions and 1 deletions
|
|
@ -27,7 +27,9 @@ trait DealsWithTenantSymlinks
|
||||||
$storagePath = str_replace('%storage_path%', $suffixBase . $tenantKey, $disks[$disk]);
|
$storagePath = str_replace('%storage_path%', $suffixBase . $tenantKey, $disks[$disk]);
|
||||||
$publicPath = str_replace('%tenant_id%', $tenantKey, $publicPath);
|
$publicPath = str_replace('%tenant_id%', $tenantKey, $publicPath);
|
||||||
|
|
||||||
|
tenancy()->central(function() use ($symlinks, $publicPath, $storagePath) {
|
||||||
$symlinks->push([public_path($publicPath) => storage_path($storagePath)]);
|
$symlinks->push([public_path($publicPath) => storage_path($storagePath)]);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
return $symlinks->mapWithKeys(fn ($item) => $item);
|
return $symlinks->mapWithKeys(fn ($item) => $item);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue