5093 Posts in 1516 Topics by 1113 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 884 Views |
-
Re: multilanuage non-object problem

31 January 2009 at 9:50am
Somewhere in TourPage.php, you're doing something like this:
DataObject::get("Something")->toDropDownMap();
Unless you're 100% sure that "Something" will not return a null set, you shouldn't run a method on that output. A better practice is this:
$stuff = DataObject::get("Something");
$map = $stuff? $stuff->toDropdownMap() : array();return new DropdownField('Name','Title', $map);
| 884 Views | ||
|
Page:
1
|
Go to Top |





