| @@ 114-125 (lines=12) @@ | ||
| 111 | * @param string $path |
|
| 112 | * @return string |
|
| 113 | */ |
|
| 114 | private function normalizePath($path) { |
|
| 115 | $path = trim($path, '/'); |
|
| 116 | //FIXME why do we sometimes get a path like 'files//username'? |
|
| 117 | $path = str_replace('//', '/', $path); |
|
| 118 | ||
| 119 | // dirname('/folder') returns '.' but internally (in the cache) we store the root as '' |
|
| 120 | if (!$path || $path === '.') { |
|
| 121 | $path = ''; |
|
| 122 | } |
|
| 123 | ||
| 124 | return $path; |
|
| 125 | } |
|
| 126 | ||
| 127 | /** |
|
| 128 | * Object Stores use a NoopScanner because metadata is directly stored in |
|
| @@ 79-89 (lines=11) @@ | ||
| 76 | /** |
|
| 77 | * @param string $path |
|
| 78 | */ |
|
| 79 | private function normalizePath($path) { |
|
| 80 | $path = trim($path, '/'); |
|
| 81 | ||
| 82 | if (!$path) { |
|
| 83 | $path = '.'; |
|
| 84 | } |
|
| 85 | ||
| 86 | $path = str_replace('#', '%23', $path); |
|
| 87 | ||
| 88 | return $path; |
|
| 89 | } |
|
| 90 | ||
| 91 | const SUBCONTAINER_FILE = '.subcontainers'; |
|
| 92 | ||