mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #234 from silverstripe-scienceninjas/fix-php-5.2-ssviewer
BUGFIX PHP 5.2 doesn't allow calling a static method like $className::$staticMethod()
This commit is contained in:
commit
c0b032dde1
@ -328,7 +328,7 @@ class SSViewer_DataPresenter extends SSViewer_Scope {
|
||||
if ($createObject) $implementer = new $implementer();
|
||||
|
||||
// Get the exposed variables
|
||||
$exposedVariables = $implementer::$variableMethod();
|
||||
$exposedVariables = call_user_func(array($implementer, $variableMethod));
|
||||
|
||||
foreach($exposedVariables as $varName => $details) {
|
||||
if (!is_array($details)) $details = array('method' => $details, 'casting' => Object::get_static('ViewableData', 'default_cast'));
|
||||
|
Loading…
Reference in New Issue
Block a user