You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, if I use the default laravel provider Illuminate\Translation\TranslationServiceProvider, it works fine and loads as expected. The developers over there suggested moving some of the logic into the boot() method so the cache driver can load properly monospice/laravel-redis-sentinel-drivers#17
Would you guys be able to help out with that and getting this different cache store supported?
The text was updated successfully, but these errors were encountered:
Looks like the problem occurs when registering the package's cache flushing Artisan command. The package's service provider ultimately resolves Laravel's cache service from the container during the provider registration phase before other providers finish initializing in the boot phase.
It seems like we want to bind the command so it resolves at run time:
if ($this->app->runningInConsole()) {
$this->app->bind('command.translator:flush', function ($app) {
returnnewCacheFlushCommand($app['translation.cache.repository'], $app['config']->get('translator.cache.enabled'));
}
$this->commands('command.translator:flush');
}
Alternatively, initialize the command in the provider's boot() method so applications can order dependencies as needed. We may want to follow the same pattern to register the file loader.
Hey guys,
Trying to use https://github.com/monospice/laravel-redis-sentinel-drivers as my cache driver, and it won't let me load the driver at all if I have the Waavi/transaction service provider in my app.php config.
However, if I use the default laravel provider
Illuminate\Translation\TranslationServiceProvider
, it works fine and loads as expected. The developers over there suggested moving some of the logic into the boot() method so the cache driver can load properly monospice/laravel-redis-sentinel-drivers#17Would you guys be able to help out with that and getting this different cache store supported?
The text was updated successfully, but these errors were encountered: