diff --git a/Mustache.php b/Mustache.php index a8abf74..4fded45 100644 --- a/Mustache.php +++ b/Mustache.php @@ -604,7 +604,7 @@ class Mustache { protected function _findVariableInContext($tag_name, $context) { foreach ($context as $view) { if (is_object($view)) { - if (is_callable(array($view, $tag_name))) { + if (method_exists($view, $tag_name)) { return $view->$tag_name(); } else if (isset($view->$tag_name)) { return $view->$tag_name;