Removing undefined variable notice for empty arrays in Sanitize::paranoid()

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6411 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
nate 2008-01-27 03:31:33 +00:00
parent b9d3c4e2e8
commit 39940856b8

View file

@ -53,6 +53,7 @@ class Sanitize {
}
if (is_array($string)) {
$cleaned = array();
foreach ($string as $key => $clean) {
$cleaned[$key] = preg_replace("/[^{$allow}a-zA-Z0-9]/", '', $clean);
}