summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Arthur <paul.arthur@flowerysong.com>2012-03-01 13:03:36 -0500
committerPaul Arthur <paul.arthur@flowerysong.com>2012-03-01 13:03:36 -0500
commitbac26188461ce0bffe90e6ce47f9d9b9d9a104c4 (patch)
tree9b4d537489b6a42cf27102c46936d3063f11d4f7
parentb5965d2513932fb6fd20bc184738793f40439f33 (diff)
downloadampache-bac26188461ce0bffe90e6ce47f9d9b9d9a104c4.tar.gz
ampache-bac26188461ce0bffe90e6ce47f9d9b9d9a104c4.tar.bz2
ampache-bac26188461ce0bffe90e6ce47f9d9b9d9a104c4.zip
Cosmetics: clean up SQL statement in Tag::get_top_tags
-rw-r--r--lib/class/tag.class.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/class/tag.class.php b/lib/class/tag.class.php
index a8309fcb..f6ae80ff 100644
--- a/lib/class/tag.class.php
+++ b/lib/class/tag.class.php
@@ -335,7 +335,7 @@ class Tag extends database_object {
* get_top_tags
* This gets the top tags for the specified object using limit
*/
- public static function get_top_tags($type,$object_id,$limit='10') {
+ public static function get_top_tags($type, $object_id, $limit = 10) {
if (!self::validate_type($type)) { return false; }
@@ -346,8 +346,8 @@ class Tag extends database_object {
$object_id = intval($object_id);
$limit = intval($limit);
- $sql = "SELECT `tag_map`.`tag_id`,`tag_map`.`user` FROM `tag_map` " .
- "WHERE `tag_map`.`object_type`='$type' AND `tag_map`.`object_id`='$object_id' " .
+ $sql = "SELECT `tag_id`, `user` FROM `tag_map` " .
+ "WHERE `object_type`='$type' AND `object_id`='$object_id' " .
"LIMIT $limit";
$db_results = Dba::read($sql);