Removing method no longer in use.

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7811 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
john 2008-10-31 19:06:05 +00:00
parent 89bf77ae01
commit 989f9f0cbc

View file

@ -2466,58 +2466,6 @@ class Model extends Overloadable {
return false;
}
/**
* Top secret
*
* @return array
* @access public
*/
function normalizeFindParams($type, $data, $altType = null, $r = array(), $_this = null) {
if ($_this == null) {
$_this = $this;
$root = true;
}
foreach ((array)$data as $name => $children) {
if (is_numeric($name)) {
$name = $children;
$children = array();
}
if (strpos($name, '.') !== false) {
$chain = explode('.', $name);
$name = array_shift($chain);
$children = array(join('.', $chain) => $children);
}
if (!empty($children)) {
if ($_this->name == $name) {
$r = array_merge($r, $this->normalizeFindParams($type, $children, $altType, $r, $_this));
} else {
if (!$_this->getAssociated($name)) {
$r[$altType][$name] = $children;
} else {
$r[$name] = $this->normalizeFindParams($type, $children, $altType, @$r[$name], $_this->{$name});;
}
}
} else {
if ($_this->getAssociated($name)) {
$r[$name] = array($type => null);
} else {
if ($altType != null) {
$r[$type][] = $name;
} else {
$r[$type] = $name;
}
}
}
}
if (isset($root)) {
return array($this->name => $r);
}
return $r;
}
/**
* Returns the ID of the last record this model inserted.
*