MDL-54837 tags: allow to specify static function as callback

This commit is contained in:
Marina Glancy 2016-06-07 08:58:59 +08:00
parent 6ee5e596b8
commit 64e9180d2e

View File

@ -1297,7 +1297,7 @@ class core_tag_tag {
require_once($CFG->dirroot . '/' . ltrim($tagarea->callbackfile, '/'));
}
$callback = $tagarea->callback;
return $callback($this, $exclusivemode, $fromctx, $ctx, $rec, $page);
return call_user_func_array($callback, [$this, $exclusivemode, $fromctx, $ctx, $rec, $page]);
}
return null;
}