Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/photos.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2019-11-18 15:50:38 +0300
committerRoeland Jago Douma <roeland@famdouma.nl>2019-11-18 15:50:38 +0300
commitf17052118d845b83255580dbd1b10b41e97d9fd4 (patch)
tree03e6f190d77c982495a75076b1509104ba1cdd65 /lib
parent71013857f9d3c68fd3d187854c45089b58b004b3 (diff)
Use relative path
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib')
-rw-r--r--lib/Controller/AlbumsController.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Controller/AlbumsController.php b/lib/Controller/AlbumsController.php
index bedcd4c9..9b412ee8 100644
--- a/lib/Controller/AlbumsController.php
+++ b/lib/Controller/AlbumsController.php
@@ -89,7 +89,7 @@ class AlbumsController extends Controller {
// properly format full path and make sure
// we're relative to the user home folder
$isRoot = $node === $userFolder;
- $path = $isRoot ? '/' : str_replace($userFolder->getPath(), '', $node->getPath());
+ $path = $userFolder->getRelativePath($node->getPath());
$result[] = [
'basename' => $isRoot ? '' : $node->getName(),