diff options
author | ewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2011-02-12 03:01:55 +0000 |
---|---|---|
committer | ewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2011-02-12 03:01:55 +0000 |
commit | 8e4a4cc6f5267d2060cafed7fd2533be29536f80 (patch) | |
tree | fa54a48d277636a8a8ccd79e283a665e28b2526e /engine/lib | |
parent | 98b61f4a6e1bb08dced4ecea4cd72939b69692f6 (diff) | |
download | elgg-8e4a4cc6f5267d2060cafed7fd2533be29536f80.tar.gz elgg-8e4a4cc6f5267d2060cafed7fd2533be29536f80.tar.bz2 |
Refs #2610: Using call_user_func in url hooks
git-svn-id: http://code.elgg.org/elgg/trunk@8139 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib')
-rw-r--r-- | engine/lib/entities.php | 6 | ||||
-rw-r--r-- | engine/lib/extender.php | 2 | ||||
-rw-r--r-- | engine/lib/relationships.php | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/engine/lib/entities.php b/engine/lib/entities.php index fb4cdd2e6..459f05ada 100644 --- a/engine/lib/entities.php +++ b/engine/lib/entities.php @@ -1783,17 +1783,17 @@ function get_entity_url($entity_guid) { if (isset($CONFIG->entity_url_handler[$entity->getType()][$entity->getSubType()])) { $function = $CONFIG->entity_url_handler[$entity->getType()][$entity->getSubType()]; if (is_callable($function)) { - $url = $function($entity); + $url = call_user_func($function, $entity); } } elseif (isset($CONFIG->entity_url_handler[$entity->getType()]['all'])) { $function = $CONFIG->entity_url_handler[$entity->getType()]['all']; if (is_callable($function)) { - $url = $function($entity); + $url = call_user_func($function, $entity); } } elseif (isset($CONFIG->entity_url_handler['all']['all'])) { $function = $CONFIG->entity_url_handler['all']['all']; if (is_callable($function)) { - $url = $function($entity); + $url = call_user_func($function, $entity); } } diff --git a/engine/lib/extender.php b/engine/lib/extender.php index f0fc98d12..90cc54805 100644 --- a/engine/lib/extender.php +++ b/engine/lib/extender.php @@ -221,7 +221,7 @@ function get_extender_url(ElggExtender $extender) { } if (is_callable($function)) { - $url = $function($extender); + $url = call_user_func($function, $extender); } if ($url == "") { diff --git a/engine/lib/relationships.php b/engine/lib/relationships.php index c032ff5b9..0370a1e82 100644 --- a/engine/lib/relationships.php +++ b/engine/lib/relationships.php @@ -432,7 +432,7 @@ function get_relationship_url($id) { } if (is_callable($function)) { - $url = $function($relationship); + $url = call_user_func($function, $relationship); } if ($url == "") { |