Explorar el Código

improve file garbage collector preview

Olivier Massot hace 3 meses
padre
commit
de0fbe6754
Se han modificado 1 ficheros con 6 adiciones y 1 borrados
  1. 6 1
      src/Service/Cron/Job/FilesGarbageCollector.php

+ 6 - 1
src/Service/Cron/Job/FilesGarbageCollector.php

@@ -50,7 +50,12 @@ class FilesGarbageCollector extends BaseCronJob
             if (($total - $i) === 50) {
             if (($total - $i) === 50) {
                 $this->ui->print('  (...)');
                 $this->ui->print('  (...)');
             }
             }
-            $this->ui->print('  * '.$file->getSlug().' (Host: '.$file->getHost()->value.' | Status: '.$file->getStatus()->value.')');
+
+            $fileExists = $this->storage->exists($file);
+
+            $this->ui->print(
+                '  * '.$file->getSlug().' (Status: '.$file->getStatus()->value.' - Exists: '.$fileExists ? 'Yes' : 'No'.')'
+            );
         }
         }
     }
     }