diff options
author | Cash Costello <cash.costello@gmail.com> | 2013-03-06 14:38:25 -0800 |
---|---|---|
committer | Cash Costello <cash.costello@gmail.com> | 2013-03-06 14:38:25 -0800 |
commit | d051e788e7ded0811dd14c6b47bcbda602737539 (patch) | |
tree | 28fbf76261692964e9391134c3cf06da022f879a /engine/lib/metadata.php | |
parent | 4b889e9cc7c629bb408fc8e470a80a7ab283fffc (diff) | |
parent | 2dbb9772881131f5739bae2d1ce5955587e9ab78 (diff) | |
download | elgg-d051e788e7ded0811dd14c6b47bcbda602737539.tar.gz elgg-d051e788e7ded0811dd14c6b47bcbda602737539.tar.bz2 |
Merge pull request #5203 from cash/bug_4393
Fixes the count issue with elgg_get_entities_from_annotation_calculation()
Diffstat (limited to 'engine/lib/metadata.php')
-rw-r--r-- | engine/lib/metadata.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/engine/lib/metadata.php b/engine/lib/metadata.php index 35b7b4dfb..96d446060 100644 --- a/engine/lib/metadata.php +++ b/engine/lib/metadata.php @@ -281,6 +281,14 @@ $access_id = ACCESS_PRIVATE, $allow_multiple = false) { * @since 1.8.0 */ function elgg_get_metadata(array $options = array()) { + + // @todo remove support for count shortcut - see #4393 + // support shortcut of 'count' => true for 'metadata_calculation' => 'count' + if (isset($options['count']) && $options['count']) { + $options['metadata_calculation'] = 'count'; + unset($options['count']); + } + $options['metastring_type'] = 'metadata'; return elgg_get_metastring_based_objects($options); } |