Skip to content

Commit 1f81a3f

Browse files
Sam WilsonPotherca
authored andcommitted
Tree filter assumes incoming path ends in a slash, so add it if it's missing
1 parent 32c5af0 commit 1f81a3f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Api.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,8 @@ private function authenticate()
255255
*/
256256
private function extractMetaDataFromTreeInfo(array $tree, $path, $recursive)
257257
{
258-
if(empty($path) === false) {
258+
if (empty($path) === false) {
259+
$path = rtrim($path, '/') . '/';
259260
$metadata = array_filter($tree, function ($entry) use ($path, $recursive) {
260261
$match = false;
261262

0 commit comments

Comments
 (0)