BUGFIX #5214 ViewableData::obj() was creating a DBField without a fieldname argument and caused problems, one example is the version panel of the CMS

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@101154 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sean Harvey 2010-03-16 22:16:56 +00:00 committed by Sam Minnee
parent f2bb6baa9f
commit 682e7d0f1a

View File

@ -391,7 +391,7 @@ class ViewableData extends Object implements IteratorAggregate {
if(!is_object($value) && $forceReturnedObject) {
$default = Object::get_static('ViewableData', 'default_cast');
$value = new $default();
$value = new $default($fieldName);
}
return $value;