diff --git a/src/SnapshotRepository.php b/src/SnapshotRepository.php index 436afad..232e9a0 100644 --- a/src/SnapshotRepository.php +++ b/src/SnapshotRepository.php @@ -19,10 +19,7 @@ public function getAll(): Collection ->filter(function (string $fileName) { $pathinfo = pathinfo($fileName); - if ( - array_key_exists('extension', $pathinfo) - && $pathinfo['extension'] === 'gz' - ) { + if (($pathinfo['extension'] ?? null) === 'gz') { $fileName = $pathinfo['filename']; }