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.
1 parent 2e6416a commit 9ea300dCopy full SHA for 9ea300d
apps/dav/lib/Connector/Sabre/Directory.php
@@ -498,11 +498,8 @@ public function getNode(): Folder {
498
}
499
500
public function getNodeForPath($path) {
501
- $nodePath = ltrim($this->path, '/');
502
- // path may be a partial path, due to caching in Tree.php
503
- $fullPath = str_starts_with($path, $nodePath) ? $path
504
- : $nodePath . '/'
505
- . $path;
+ $nodeIsRoot = $this->path === '/';
+ $fullPath = $nodeIsRoot ? $this->path . $path : $this->path . '/' . $path;
506
507
try {
508
[$destinationDir, $destinationName] = \Sabre\Uri\split($fullPath);
0 commit comments