Fix incorrect logic in r66544

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/branches/2.3@66546 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Andrew O'Neil 2008-11-25 01:56:57 +00:00 committed by Sam Minnee
parent cc982ec915
commit 3aa7ad3212

View File

@ -83,7 +83,7 @@ class SecurityAdmin extends LeftAndMain implements PermissionProvider {
$result = '';
// Make sure we only autocomplete on keys that actually exist, and that we don't autocomplete on password
if(!array_key_exists($fieldName, singleton($this->stat('subitem_class'))->stat('db')) && $fieldName != 'Password') return;
if(!array_key_exists($fieldName, singleton($this->stat('subitem_class'))->stat('db')) || $fieldName == 'Password') return;
$matches = DataObject::get($this->stat('subitem_class'),"$fieldName LIKE '" . Convert::raw2sql($fieldVal) . "%'");
if($matches) {