From a16c2d0a26826c2cbb5749dec5146167449b1e51 Mon Sep 17 00:00:00 2001 From: rembo10 Date: Mon, 13 Jul 2015 15:09:01 -0700 Subject: [PATCH] Fix for #2279: What.cd not honoring custom search string --- headphones/searcher.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/headphones/searcher.py b/headphones/searcher.py index e92f43f4..6af32131 100644 --- a/headphones/searcher.py +++ b/headphones/searcher.py @@ -1325,7 +1325,10 @@ def searchTorrent(album, new=False, losslessOnly=False, albumlength=None, choose logger.info(u"Searching %s..." % provider) all_torrents = [] for search_format in search_formats: - all_torrents.extend(gazelle.search_torrents(artistname=semi_clean_artist_term, + if usersearchterm: + all_torrents.extend(gazelle.search_torrents(searchstr=usersearchterm, format=search_format, encoding=bitrate_string)['results']) + else: + all_torrents.extend(gazelle.search_torrents(artistname=semi_clean_artist_term, groupname=semi_clean_album_term, format=search_format, encoding=bitrate_string)['results'])