]> git.mxchange.org Git - friendica.git/commitdiff
Fix query string parsing border case in Util\Proxy
authorHypolite Petovan <mrpetovan@gmail.com>
Sun, 5 Aug 2018 13:57:04 +0000 (15:57 +0200)
committerHypolite Petovan <mrpetovan@gmail.com>
Sun, 5 Aug 2018 13:57:04 +0000 (15:57 +0200)
src/Util/Proxy.php

index bb26185f4656595098ff47f6983badbd09a19d3e..3473e8d167ddf9b578d8390f02d5b4d3fe7af83a 100644 (file)
@@ -180,16 +180,8 @@ class Proxy
        {
                $query = parse_url($url, PHP_URL_QUERY);
                $query = html_entity_decode($query);
-               $query_list = explode('&', $query);
 
-               $arr = [];
-
-               foreach ($query_list as $key_value) {
-                       $key_value_list = explode('=', $key_value);
-                       $arr[$key_value_list[0]] = $key_value_list[1];
-               }
-
-               unset($url, $query_list, $url);
+               parse_str($query, $arr);
 
                return $arr;
        }