diff options
Diffstat (limited to 'system/libraries')
-rw-r--r-- | system/libraries/Router.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/system/libraries/Router.php b/system/libraries/Router.php index d4d1b2fdb..886433f37 100644 --- a/system/libraries/Router.php +++ b/system/libraries/Router.php @@ -295,7 +295,10 @@ class CI_Router { // can be unreliable in some environments if (is_array($_GET) AND count($_GET) == 1) { - return current(array_keys($_GET)); + // Note: Due to a bug in current() that affects some versions + // of PHP we can not pass function call directly into it + $keys = array_keys($_GET); + return current($keys); } // Is there a PATH_INFO variable? |