1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-12 15:34:03 +00:00

Remove asset()

This commit is contained in:
Samuel Štancl 2019-01-19 23:26:26 +01:00
parent b786643094
commit 25bc3f81b3

View file

@ -40,8 +40,7 @@ trait BootstrapsTenancy
{
$old = [
"storage_disks" => [],
"storage_path" => $this->app->storagePath,
"asset" => asset(''),
"storage_path" => $this->app->storagePath(),
];
$suffix = $this->app['config']['tenancy.filesystem.suffix_base'] . tenant('uuid');
@ -49,7 +48,7 @@ trait BootstrapsTenancy
// Storage facade
foreach ($this->app['config']['tenancy.filesystem.disks'] as $disk) {
$root = $this->app['config']["filesystems.disks.{$disk}.root"];
\Storage::disk($disk)->getAdapter()->setPathPrefix(
$root . "/{$suffix}"
);
@ -60,9 +59,6 @@ trait BootstrapsTenancy
// storage_path()
$this->app->useStoragePath($this->app->storagePath() . "/{$suffix}");
// asset()
$this->app('url')->forceRootUrl(asset('') . "/{$suffix}");
$this->oldStoragePaths = $old;
}
}