summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2014-04-24 10:48:52 +0200
committerMax Kellermann <max@duempel.org>2014-04-24 10:48:52 +0200
commit27002ad1eaee1fcbf57f5ae5bb8a5b0692d85681 (patch)
treee2138ecdf826a407ca40644fab85418a62101d24
parent986dd2fac1269b2d40f2ba2b2636eb5d312dc773 (diff)
db/Helpers: "list" on album artist falls back to the artist tag
-rw-r--r--NEWS1
-rw-r--r--src/db/Helpers.cxx5
2 files changed, 5 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index d48dfc44f..a64400e32 100644
--- a/NEWS
+++ b/NEWS
@@ -5,6 +5,7 @@ ver 0.19 (not yet released)
- "listneighbors" lists file servers on the local network
- "playlistadd" supports file:///
- "idle" with unrecognized event name fails
+ - "list" on album artist falls back to the artist tag
* database
- proxy: forward "idle" events
- proxy: copy "Last-Modified" from remote directories
diff --git a/src/db/Helpers.cxx b/src/db/Helpers.cxx
index 719fa8741..43b0e8159 100644
--- a/src/db/Helpers.cxx
+++ b/src/db/Helpers.cxx
@@ -58,7 +58,10 @@ CollectTags(StringSet &set, TagType tag_type, const LightSong &song)
assert(song.tag != nullptr);
const Tag &tag = *song.tag;
- if (!CheckUniqueTag(set, tag, tag_type))
+ if (!CheckUniqueTag(set, tag, tag_type) &&
+ (tag_type != TAG_ALBUM_ARTIST ||
+ /* fall back to "Artist" if no "AlbumArtist" was found */
+ !CheckUniqueTag(set, tag, TAG_ARTIST)))
set.insert("");
return true;