]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix path for files from root folder 3948/head
authorMorris Jobke <hey@morrisjobke.de>
Wed, 22 Mar 2017 23:17:37 +0000 (17:17 -0600)
committerMorris Jobke <hey@morrisjobke.de>
Wed, 22 Mar 2017 23:17:37 +0000 (17:17 -0600)
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
apps/files_trashbin/lib/Helper.php

index faf84369e72f76449bb416173063ad7b0d0c83ea..a309d533e5498727805a00aaa967d5caff98070a 100644 (file)
@@ -91,7 +91,11 @@ class Helper {
                                'permissions' => Constants::PERMISSION_ALL - Constants::PERMISSION_SHARE
                        );
                        if ($originalPath) {
-                               $i['extraData'] = $originalPath . '/' . $originalName;
+                               if ($originalPath !== '.') {
+                                       $i['extraData'] = $originalPath . '/' . $originalName;
+                               } else {
+                                       $i['extraData'] = $originalName;
+                               }
                        }
                        $result[] = new FileInfo($absoluteDir . '/' . $i['name'], $storage, $internalPath . '/' . $i['name'], $i, $mount);
                }