We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 277a7b9 + 5158bbf commit 937b746Copy full SHA for 937b746
1 file changed
lib/private/Files/Storage/Local.php
@@ -282,7 +282,11 @@ public function isUpdatable($path) {
282
public function file_exists($path) {
283
if ($this->caseInsensitive) {
284
$fullPath = $this->getSourcePath($path);
285
- $content = scandir(dirname($fullPath), SCANDIR_SORT_NONE);
+ $parentPath = dirname($fullPath);
286
+ if (!is_dir($parentPath)) {
287
+ return false;
288
+ }
289
+ $content = scandir($parentPath, SCANDIR_SORT_NONE);
290
return is_array($content) && array_search(basename($fullPath), $content) !== false;
291
} else {
292
return file_exists($this->getSourcePath($path));
0 commit comments