Modifs cache
This commit is contained in:
@@ -4,6 +4,7 @@ namespace Meoran\Images\Console\Commands;
|
||||
|
||||
use FilesystemIterator;
|
||||
use Illuminate\Console\Command;
|
||||
use Illuminate\Filesystem\Filesystem;
|
||||
use RecursiveDirectoryIterator;
|
||||
use RecursiveIteratorIterator;
|
||||
|
||||
@@ -39,8 +40,13 @@ class CacheGarbageCollectorCommand extends Command
|
||||
*/
|
||||
public function handle()
|
||||
{
|
||||
$path = storage_path('image.path');
|
||||
$files = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path, FilesystemIterator::SKIP_DOTS));
|
||||
$base = config('image.cache.path');
|
||||
if (empty($base)) {
|
||||
$this->line("Le cache n'est pas configuré. End...");
|
||||
return;
|
||||
}
|
||||
$fs = new Filesystem();
|
||||
$files = collect($fs->allFiles($base));
|
||||
|
||||
/**
|
||||
* @var \SplFileInfo $b
|
||||
|
Reference in New Issue
Block a user