]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Refs #3510, #3366. Added warning about count vs sum in egef_annotation_count() to...
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>
Thu, 9 Jun 2011 01:58:26 +0000 (01:58 +0000)
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>
Thu, 9 Jun 2011 01:58:26 +0000 (01:58 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@9147 36083f99-b078-4883-b0ff-0f9b5a30f544

engine/lib/deprecated-1.8.php

index 12398c8d5ee4a5125265d5db66b343981f3852b2..a04907a6d3a6a09394b647519e815eb7657d95a0 100644 (file)
@@ -208,6 +208,12 @@ function get_entities_from_annotations_calculate_x($sum = "sum", $entity_type =
 /**
  * Returns entities ordered by the sum of an annotation
  *
+ * @warning This is function uses sum instead of count. THIS IS SLOW. See #3366.
+ *          This should be used when you have annotations with different values and you
+ *          want a list of entities ordered by the sum of all of those values.
+ *          If you want a list of entities ordered by the number of annotations on each entity,
+ *          use __get_entities_from_annotations_calculate_x() and pass 'count' as the first param.
+ *
  * @deprecated 1.8 Use elgg_get_entities_from_annotation_calculation()
  *
  * @param string $entity_type    Type of Entity