aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-12-17 12:44:19 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2009-12-17 12:44:19 +0000
commit85dd010eb40fd46b52f2e265fe7e5bdc39aa7d7b (patch)
tree78ed191969fddda0c79fc6bb78770373f9c54bdb
parent583942ee08e987fa7e9e68d4c67b9b9590fa2b0f (diff)
downloadelgg-85dd010eb40fd46b52f2e265fe7e5bdc39aa7d7b.tar.gz
elgg-85dd010eb40fd46b52f2e265fe7e5bdc39aa7d7b.tar.bz2
when asking for a count of entities, we now return an integer rather than a string
git-svn-id: http://code.elgg.org/elgg/trunk@3764 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r--engine/lib/entities.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/engine/lib/entities.php b/engine/lib/entities.php
index f86299c6e..358a45c3c 100644
--- a/engine/lib/entities.php
+++ b/engine/lib/entities.php
@@ -549,7 +549,7 @@ abstract class ElggEntity implements
}
/**
- * Returns whether the given user (or current user) has the ability to write to this group.
+ * Returns whether the given user (or current user) has the ability to write to this container.
*
* @param int $user_guid The user.
* @return bool
@@ -1640,7 +1640,8 @@ function get_entity($guid) {
*
* joins => array() Additional joins
*
- * @return array
+ * @return if count, int
+ * if not count, array or false if no entities
*/
function elgg_get_entities(array $options = array()) {
global $CONFIG;
@@ -1773,7 +1774,7 @@ function elgg_get_entities(array $options = array()) {
return $dt;
} else {
$total = get_data_row($query);
- return $total->total;
+ return (int)$total->total;
}
}