disk()); $pruneDate = Date::now()->subHours($this->hours); $results = []; foreach ($fs->allFiles() as $path) { $lastModified = Date::createFromTimestamp($fs->lastModified($path)); if ($lastModified->isBefore($pruneDate)) { $result = $fs->delete($path); $results[$path] = $result; } } return new PruneResults($this->disk(), $results); } /** * Processes to be completed after handling action. * * @param StorageResults $storageResults * @return null * * @throws Exception */ public function then(StorageResults $storageResults): null { $reconcileResults = $this->reconcileRepositories(); $reconcileResults->toLog(); return null; } }