Fix glob return

This commit is contained in:
bohwaz 2023-09-11 00:48:59 +02:00
parent a115f54775
commit ef2a3eeea6

View file

@ -463,7 +463,7 @@ class Storage extends AbstractStorage
static protected function glob(string $path, string $pattern = '', int $flags = 0): array static protected function glob(string $path, string $pattern = '', int $flags = 0): array
{ {
$path = preg_replace('/[\*\?\[\]]/', '\\\\$0', $path); $path = preg_replace('/[\*\?\[\]]/', '\\\\$0', $path);
return glob($path . $pattern, $flags); return glob($path . $pattern, $flags) ?: [];
} }
static public function getDirectorySize(string $path): int static public function getDirectorySize(string $path): int