Revert "Replace COUNT(DISTINCT primary_key) with COUNT(*)"
Genres are required as part of the count queries, so filter by genres work
This commit is contained in:
@@ -76,6 +76,7 @@ func artistFilter(field string, value interface{}) Sqlizer {
|
||||
|
||||
func (r *albumRepository) CountAll(options ...model.QueryOptions) (int64, error) {
|
||||
sql := r.newSelectWithAnnotation("album.id")
|
||||
sql = r.withGenres(sql) // Required for filtering by genre
|
||||
return r.count(sql, options...)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user