mirror of
https://github.com/YGGverse/next.git
synced 2025-01-26 23:04:49 +00:00
set empty request value to / by protocol specification
This commit is contained in:
parent
69c47f0655
commit
6eec298bfe
@ -187,6 +187,8 @@ $server->start(
|
|||||||
$request
|
$request
|
||||||
);
|
);
|
||||||
|
|
||||||
|
$request = empty($request) ? '/' : $request;
|
||||||
|
|
||||||
// Build realpath
|
// Build realpath
|
||||||
$realpath = realpath(
|
$realpath = realpath(
|
||||||
NEXT_PATH .
|
NEXT_PATH .
|
||||||
@ -338,7 +340,7 @@ $server->start(
|
|||||||
(string) (int) is_string($response),
|
(string) (int) is_string($response),
|
||||||
(string) parse_url($url, PHP_URL_HOST),
|
(string) parse_url($url, PHP_URL_HOST),
|
||||||
(string) parse_url($url, PHP_URL_PORT),
|
(string) parse_url($url, PHP_URL_PORT),
|
||||||
(string) str_replace('%', '%%', empty($request) ? '/' : $request),
|
(string) str_replace('%', '%%', $request),
|
||||||
(string) str_replace('%', '%%', empty($realpath) ? '!' : $realpath),
|
(string) str_replace('%', '%%', empty($realpath) ? '!' : $realpath),
|
||||||
(string) mb_strlen((string) $response)
|
(string) mb_strlen((string) $response)
|
||||||
],
|
],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user