From 7acd581d9441fb8ada4c46c58f4ec30a01507506 Mon Sep 17 00:00:00 2001 From: admin Date: Mon, 23 Oct 2006 21:37:22 +0000 Subject: --- system/libraries/Router.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'system/libraries') 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? -- cgit v1.2.3-24-g4f1b