Adding fix for #2640, fixes nested array issues with Router::stripEscape()

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5257 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
phpnut 2007-06-07 19:27:42 +00:00
parent eea7d7aafc
commit 02508cfb02

View file

@ -785,6 +785,7 @@ class Router extends Object {
* @static
*/
function stripEscape($param) {
$_this =& Router::getInstance();
if(!is_array($param) || empty($param)) {
if(is_bool($param)) {
return $param;
@ -798,7 +799,7 @@ class Router extends Object {
$return[$key] = preg_replace('/^[\\t ]*(?:-!)+/', '', $value);
} else {
foreach ($value as $array => $string) {
$return[$key][$array] = preg_replace('/^[\\t ]*(?:-!)+/', '', $string);
$return[$key][$array] = $_this->stripEscape($string);
}
}
}