use call_user_func for callbacks

This commit is contained in:
Evan Prodromou 2009-03-08 11:49:34 -07:00
parent 2133d5a4e7
commit e55808698b
1 changed files with 1 additions and 1 deletions

View File

@ -467,7 +467,7 @@ function common_replace_urls_callback($text, $callback) {
$url = (mb_strpos($orig_url, htmlspecialchars($url)) === FALSE) ? $url:htmlspecialchars($url);
// Call user specified func
$modified_url = $callback($url);
$modified_url = call_user_func($callback, $url);
// Replace it!
$start = mb_strpos($text, $url, $offset);