Skip to content

Commit 7bc53a3

Browse files
SniperSisterlaoneo
andauthored
remove query parameters from API route variables (#40998)
Co-authored-by: Allon Moritz <[email protected]>
1 parent 49b46d0 commit 7bc53a3

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

libraries/src/Router/ApiRouter.php

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,6 @@ public function parseApiRoute($method = 'GET')
9999
// Get the path from the route and remove and leading or trailing slash.
100100
$routePath = $this->getRoutePath();
101101

102-
$query = Uri::getInstance()->getQuery(true);
103-
104-
// Remove the public key as it is only supported coming from the route definition
105-
if (array_key_exists('public', $query)) {
106-
unset($query['public']);
107-
}
108-
109102
// Iterate through all of the known routes looking for a match.
110103
foreach ($this->routes as $route) {
111104
if (\in_array($method, $route->getMethods())) {
@@ -119,11 +112,6 @@ public function parseApiRoute($method = 'GET')
119112

120113
$controller = preg_split("/[.]+/", $route->getController());
121114

122-
/** @deprecated 4.3 will be removed in 5.0
123-
* Query parameters will not be merged into route variables from 5.0
124-
*/
125-
$vars = array_merge($vars, $query);
126-
127115
return [
128116
'controller' => $controller[0],
129117
'task' => $controller[1],

0 commit comments

Comments
 (0)