File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -324,7 +324,7 @@ public function hasQueryParameter($name)
324324 */
325325 public function getQueryParameters ()
326326 {
327- return empty ( $ this -> info [ ' query ' ]) ? [] : $ this ->info ['query ' ];
327+ return $ this ->info ['query ' ];
328328 }
329329
330330 /**
@@ -442,14 +442,16 @@ protected function parseUrl($url)
442442
443443 $ this ->info = parse_url ($ url );
444444
445- if (isset ($ this ->info ['query ' ])) {
445+ if (empty ($ this ->info ['query ' ])) {
446+ $ this ->info ['query ' ] = [];
447+ } else {
446448 $ queryString = preg_replace_callback ('/(^|(?<=&))[^=[&]+/ ' , function ($ key ) {
447449 return base64_encode (urldecode ($ key [0 ]));
448450 }, $ this ->info ['query ' ]);
449451
450452 parse_str ($ queryString , $ query );
451453
452- $ this ->info ['query ' ] = self ::fixQuery ($ query );
454+ $ this ->info ['query ' ] = $ query ? self ::fixQuery ($ query ) : [] ;
453455 }
454456
455457 if (isset ($ this ->info ['path ' ])) {
You can’t perform that action at this time.
0 commit comments