From 38e9bc2adbacb4ce4a7801996ec143f067a9d731 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bj=C3=B6rn=20Schie=C3=9Fle?= Date: Tue, 9 Oct 2012 16:21:46 +0200 Subject: [PATCH] extract the right parent directory from the path add parent directory to the file cache if it does not exist yet. --- lib/filecache.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/filecache.php b/lib/filecache.php index d68525d9a54..8fcb6fd9404 100644 --- a/lib/filecache.php +++ b/lib/filecache.php @@ -79,7 +79,7 @@ class OC_FileCache{ // add parent directory to the file cache if it does not exist yet. if ($parent == -1 && $fullpath != $root) { - $parentDir = substr(dirname($path), 0, strrpos(dirname($path), DIRECTORY_SEPARATOR)); + $parentDir = dirname($path); self::scanFile($parentDir); $parent = self::getParentId($fullpath); } -- 2.39.5