BUGFIX call to $field->Name should be $field->Name() - see Form->Fields() for the correct way

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@55161 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sean Harvey 2008-05-26 23:53:24 +00:00
parent 475361fafd
commit 3f8591a807

View File

@ -259,7 +259,7 @@ class Form extends ViewableData {
*/
function dataFieldByName($name) {
foreach($this->getExtraFields() as $field) {
if(!$this->fields->dataFieldByName($field->Name)) $this->fields->push($field);
if(!$this->fields->dataFieldByName($field->Name())) $this->fields->push($field);
}
return $this->fields->dataFieldByName($name);