]> source.dussan.org Git - nextcloud-server.git/commitdiff
don't emit rename hooks on partial file renames
authorJörn Friedrich Dreyer <jfd@butonic.de>
Fri, 10 May 2013 10:01:50 +0000 (12:01 +0200)
committerLukas Reschke <lukas@statuscode.ch>
Fri, 10 May 2013 13:19:02 +0000 (15:19 +0200)
lib/files/view.php

index 2e8dfd3b4d04c42273340c5483024d56533010dc..a738b8cac8a085d4d91360d03acb5147401b5a88 100644 (file)
@@ -350,7 +350,7 @@ class View {
                                return false;
                        }
                        $run = true;
-                       if ($this->fakeRoot == Filesystem::getRoot()) {
+                       if ($this->fakeRoot == Filesystem::getRoot() && !Cache\Scanner::isPartialFile($path1)) {
                                \OC_Hook::emit(
                                        Filesystem::CLASSNAME, Filesystem::signal_rename,
                                        array(
@@ -378,7 +378,7 @@ class View {
                                        list($storage1, $internalPath1) = Filesystem::resolvePath($absolutePath1 . $postFix1);
                                        $storage1->unlink($internalPath1);
                                }
-                               if ($this->fakeRoot == Filesystem::getRoot()) {
+                               if ($this->fakeRoot == Filesystem::getRoot() && !Cache\Scanner::isPartialFile($path1)) {
                                        \OC_Hook::emit(
                                                Filesystem::CLASSNAME,
                                                Filesystem::signal_post_rename,