diff options
author | Paul Arthur <paul.arthur@flowerysong.com> | 2013-05-13 21:36:12 -0400 |
---|---|---|
committer | Paul Arthur <paul.arthur@flowerysong.com> | 2013-05-13 21:36:12 -0400 |
commit | 9a62b49341445f32f2f299f29f3a4340637ba93c (patch) | |
tree | 2d9e5ebb9bc56c0e2f6a297df4af6b267453a0c0 | |
parent | 6e33efbe23d1791f182c428cd92ecc8935d3ca51 (diff) | |
download | ampache-9a62b49341445f32f2f299f29f3a4340637ba93c.tar.gz ampache-9a62b49341445f32f2f299f29f3a4340637ba93c.tar.bz2 ampache-9a62b49341445f32f2f299f29f3a4340637ba93c.zip |
Make Catalog::count_songs use the correct variable
Fixes GH#23
-rwxr-xr-x | docs/CHANGELOG.md | 1 | ||||
-rw-r--r-- | lib/class/catalog.class.php | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 4a41c7bd..54130ede 100755 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -3,6 +3,7 @@ CHANGELOG 3.6-FUTURE ---------- +- Fixed catalog song stats (reported by stebe) - Fixed ACL text field length to allow entry of IPv6 addresses (reported by Baggypants) - Fixed regression preventing the use of an existing database during diff --git a/lib/class/catalog.class.php b/lib/class/catalog.class.php index 1e2878bf..7d5d4746 100644 --- a/lib/class/catalog.class.php +++ b/lib/class/catalog.class.php @@ -347,7 +347,7 @@ class Catalog extends database_object { * in this catalog. */ public static function count_songs($id = null) { - $where_sql = $catalog_id ? 'WHERE `catalog` = ?' : ''; + $where_sql = $id ? 'WHERE `catalog` = ?' : ''; $params = $id ? array($id) : null; $sql = 'SELECT COUNT(`id`), SUM(`time`), SUM(`size`) FROM `song` ' . |