diff options
author | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-06-17 13:40:51 +0000 |
---|---|---|
committer | marcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2009-06-17 13:40:51 +0000 |
commit | af7cac705174546ca6684749538e206aa509bb98 (patch) | |
tree | 19a640422ecae4bc1c623b43b82c55863dc41d48 /engine/lib | |
parent | a7880dfd3c39c23f26f4f0f1d1cc059707289ff8 (diff) | |
download | elgg-af7cac705174546ca6684749538e206aa509bb98.tar.gz elgg-af7cac705174546ca6684749538e206aa509bb98.tar.bz2 |
Refs #964: Correct detection of type.
git-svn-id: https://code.elgg.org/elgg/trunk@3341 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib')
-rw-r--r-- | engine/lib/elgglib.php | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/engine/lib/elgglib.php b/engine/lib/elgglib.php index 87f2ec278..7822919c5 100644 --- a/engine/lib/elgglib.php +++ b/engine/lib/elgglib.php @@ -790,7 +790,16 @@ */ function elgg_view_entity_annotations(ElggEntity $entity, $full = true) { - $annotations = trigger_plugin_hook('entity:annotate', $entity_class, + $classes = array( + 'ElggUser' => 'user', + 'ElggObject' => 'object', + 'ElggSite' => 'site', + 'ElggGroup' => 'group' + ); + + $entity_class = get_class($entity); + + $annotations = trigger_plugin_hook('entity:annotate', $classes[$entity_class], array( 'entity' => $entity, 'full' => $full, |