Skip to content

Commit d32e090

Browse files
authored
Merge pull request #666 from riku22/fix_request_base
Fixed an issue where `Flight::request()->base` would display only a yen symbol in Windows environments without a parent directory
2 parents 854f668 + 40f176f commit d32e090

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

flight/net/Request.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,9 @@ public function __construct(array $config = [])
173173
$base = str_replace(['\\', ' '], ['/', '%20'], $base);
174174
}
175175
$base = dirname($base);
176+
if ($base === '\\') {
177+
$base = '/';
178+
}
176179
$config = [
177180
'url' => $url,
178181
'base' => $base,

0 commit comments

Comments
 (0)