aboutsummaryrefslogtreecommitdiffstats
path: root/boot.php
diff options
context:
space:
mode:
Diffstat (limited to 'boot.php')
-rw-r--r--boot.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/boot.php b/boot.php
index 5fa314eee..ff73c0146 100644
--- a/boot.php
+++ b/boot.php
@@ -60,7 +60,7 @@ require_once('include/bbcode.php');
require_once('include/items.php');
define('PLATFORM_NAME', 'hubzilla');
-define('STD_VERSION', '7.1.4');
+define('STD_VERSION', '7.1.6');
define('ZOT_REVISION', '6.0');
define('DB_UPDATE_VERSION', 1252);
@@ -915,9 +915,14 @@ class App {
if ((x($_SERVER, 'QUERY_STRING')) && substr($_SERVER['QUERY_STRING'], 0, 2) === "q=") {
self::$query_string = str_replace(['<', '>'], ['&lt;', '&gt;'], substr($_SERVER['QUERY_STRING'], 2));
+
// removing trailing / - maybe a nginx problem
if (substr(self::$query_string, 0, 1) == "/")
self::$query_string = substr(self::$query_string, 1);
+
+ // trim trailing '&' if no extra args are present
+ self::$query_string = rtrim(self::$query_string, '&');
+
// change the first & to ?
self::$query_string = preg_replace('/&/', '?', self::$query_string, 1);
}