/** * @param Application $app */ protected function registerCache(Application $app) { $app->singleton('cache.store', function ($app) { return new \Illuminate\Cache\Repository($app->make('cache.filestore')); }); $app->singleton('cache.filestore', function ($app) { return new \Illuminate\Cache\FileStore(new \Illuminate\Filesystem\Filesystem(), $app->storagePath() . '/cache'); }); $app->alias('cache.filestore', 'Illuminate\\Contracts\\Cache\\Store'); $app->alias('cache.store', 'Illuminate\\Contracts\\Cache\\Repository'); }