|
@@ -215,10 +215,6 @@ class Mustache_Context
|
|
|
if (!($frame instanceof Closure)) {
|
|
if (!($frame instanceof Closure)) {
|
|
|
// Note that is_callable() *will not work here*
|
|
// Note that is_callable() *will not work here*
|
|
|
// See https://github.com/bobthecow/mustache.php/wiki/Magic-Methods
|
|
// See https://github.com/bobthecow/mustache.php/wiki/Magic-Methods
|
|
|
- if (method_exists($frame, $id)) {
|
|
|
|
|
- return $frame->$id();
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
if (isset($frame->$id)) {
|
|
if (isset($frame->$id)) {
|
|
|
return $frame->$id;
|
|
return $frame->$id;
|
|
|
}
|
|
}
|
|
@@ -226,6 +222,11 @@ class Mustache_Context
|
|
|
if ($frame instanceof ArrayAccess && isset($frame[$id])) {
|
|
if ($frame instanceof ArrayAccess && isset($frame[$id])) {
|
|
|
return $frame[$id];
|
|
return $frame[$id];
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+ if (method_exists($frame, $id)) {
|
|
|
|
|
+ return $frame->$id();
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
|
|
|