Skip to content

Commit 1db476a

Browse files
authored
Update SimpleRouter.php
1 parent e8ece71 commit 1db476a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Tqdev/PhpCrudApi/Middleware/Router/SimpleRouter.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,9 @@ private function detectBasePath(string $basePath): string
5050
return substr($fullPath, 0, -1 * strlen($path));
5151
}
5252
}
53-
return $fullPath;
53+
if ('/' . basename(__FILE__) == $fullPath) {
54+
return $fullPath;
55+
}
5456
}
5557
return '/';
5658
}

0 commit comments

Comments
 (0)