aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions.php
diff options
context:
space:
mode:
authorOleg Pudeyev <oleg@bsdpower.com>2011-09-05 02:48:54 -0400
committerOleg Pudeyev <oleg@bsdpower.com>2011-09-05 02:48:54 -0400
commitdce62b5271a1c7707a83e2c820eeefa60176b0f0 (patch)
treecb2ff9976a119acab6b90264fdf50d46cbc819f0 /phpBB/includes/functions.php
parent6216e6748c99eef54ce366c77007ca161b4b0e19 (diff)
parentcf5f0cce83486af04e94e2edfd0b5ad547cdf484 (diff)
downloadforums-dce62b5271a1c7707a83e2c820eeefa60176b0f0.tar
forums-dce62b5271a1c7707a83e2c820eeefa60176b0f0.tar.gz
forums-dce62b5271a1c7707a83e2c820eeefa60176b0f0.tar.bz2
forums-dce62b5271a1c7707a83e2c820eeefa60176b0f0.tar.xz
forums-dce62b5271a1c7707a83e2c820eeefa60176b0f0.zip
Merge branch 'develop-olympus' into develop
* develop-olympus: [ticket/10321] Add descriptions to the unit tests [ticket/10321] Do not append the ? if the param-list is empty anyway.
Diffstat (limited to 'phpBB/includes/functions.php')
-rw-r--r--phpBB/includes/functions.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/phpBB/includes/functions.php b/phpBB/includes/functions.php
index 47ff270b76..e73f90a772 100644
--- a/phpBB/includes/functions.php
+++ b/phpBB/includes/functions.php
@@ -1999,6 +1999,12 @@ function append_sid($url, $params = false, $is_amp = true, $session_id = false)
{
global $_SID, $_EXTRA_URL, $phpbb_hook;
+ if ($params === '' || (is_array($params) && empty($params)))
+ {
+ // Do not append the ? if the param-list is empty anyway.
+ $params = false;
+ }
+
// Developers using the hook function need to globalise the $_SID and $_EXTRA_URL on their own and also handle it appropriately.
// They could mimic most of what is within this function
if (!empty($phpbb_hook) && $phpbb_hook->call_hook(__FUNCTION__, $url, $params, $is_amp, $session_id))