summaryrefslogtreecommitdiff
path: root/modules/tag/helpers
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2011-04-23 07:42:54 -0700
committerBharat Mediratta <bharat@menalto.com>2011-04-23 07:42:54 -0700
commitaa949003545c50c1d2175167b8f69ae65d6dc217 (patch)
tree5e7a5260bf57d76904cac4bd135dca72743c8363 /modules/tag/helpers
parent171e4fd0ee6493bb82bb1de3017b83319e7fc5e4 (diff)
parent6b90b8e7f6ac2b641aa5a1da173ea3191c1921e3 (diff)
Merge branch 'master' of github.com:gallery/gallery3
Diffstat (limited to 'modules/tag/helpers')
-rw-r--r--modules/tag/helpers/tag.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/tag/helpers/tag.php b/modules/tag/helpers/tag.php
index 733215b3..742783d1 100644
--- a/modules/tag/helpers/tag.php
+++ b/modules/tag/helpers/tag.php
@@ -48,6 +48,7 @@ class tag_Core {
* @return ORM_Iterator of Tag_Model in descending tag count order
*/
static function popular_tags($count) {
+ $count = $count >= 1 ? $count : 30;
return ORM::factory("tag")
->order_by("count", "DESC")
->limit($count)