MCPcopy Create free account
hub / github.com/error311/FileRise / hrefToRelative

Method hrefToRelative

src/FileRise/Storage/WebDavAdapter.php:406–415  ·  view source on GitHub ↗
(string $href)

Source from the content-addressed store, hash-verified

404 }
405
406 private function hrefToRelative(string $href): string
407 {
408 $path = (string)(parse_url($href, PHP_URL_PATH) ?? '');
409 $path = rawurldecode($path);
410 $base = $this->basePath;
411 if ($base !== '' && $base !== '/' && str_starts_with($path, $base)) {
412 $path = substr($path, strlen($base));
413 }
414 return ltrim($path, '/');
415 }
416
417 private function propFind(string $path, int $depth): array
418 {

Callers 1

listMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected