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

Update PrefixCacheTenancyBootstrapper.php

This commit is contained in:
Abrar Ahmad 2022-11-22 14:13:10 +05:00
parent c5f7de4b0e
commit 2302571f6a

View file

@ -40,17 +40,9 @@ class PrefixCacheTenancyBootstrapper implements TenancyBootstrapper
$this->app['cache']->forgetDriver($this->storeName);
// This is important because the `CacheManager` will have the `$app['config']` array cached
// with old prefixes on the `cache` instance. Simply calling `forgetDriver` only removes
// the `$store` but doesn't update the `$app['config']`.
$this->app->forgetInstance('cache');
//This is important because the Cache Repository is using an old version of the CacheManager
$this->app->forgetInstance('cache.store');
// Forget the cache repository in the container
$this->app->forgetInstance(Repository::class);
Cache::clearResolvedInstances();
}
}