mirror of
https://github.com/YGGverse/Pulsar.git
synced 2026-03-31 09:45:32 +00:00
simplify construction
This commit is contained in:
parent
d0a539db91
commit
30bf68267e
1 changed files with 4 additions and 4 deletions
|
|
@ -114,15 +114,15 @@ $server->setHandler(
|
|||
// Filter path request
|
||||
$path = preg_replace(
|
||||
[
|
||||
'/\\\/', // unify separators
|
||||
'/(^|\/)[\.]+/', // hidden items started with dot
|
||||
'/[\.]+\//', // relative directory paths
|
||||
'/[\/]+\//', // remove extra slashes
|
||||
],
|
||||
DIRECTORY_SEPARATOR,
|
||||
trim(
|
||||
str_replace(
|
||||
'\\', '/', filter_var($request->getPath(), FILTER_SANITIZE_URL)
|
||||
)
|
||||
filter_var(
|
||||
$request->getPath(),
|
||||
FILTER_SANITIZE_URL
|
||||
)
|
||||
);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue