fixes #5233, uppercase fields in containable

git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7452 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
gwoo 2008-08-11 15:11:06 +00:00
parent 1ba01ef786
commit 8cb73ead3c

View file

@ -300,7 +300,7 @@ class ContainableBehavior extends ModelBehavior {
continue;
}
$optionKey = in_array($key, $options, true);
if (!$optionKey && is_string($key) && preg_match('/^[a-z(]/', $key) && (!isset($Model->{$key}) || !is_object($Model->{$key}))) {
if (!$optionKey && is_string($key) && preg_match('/^[a-zA-Z(]/', $key) && (!isset($Model->{$key}) || !is_object($Model->{$key}))) {
$option = 'fields';
$val = array($key);
if ($key{0} == '(') {