Commit e60d729b authored by Alexander Stippich's avatar Alexander Stippich

Use artist when inserting a new album when album artist is not available

Summary:
When adding new tracks, artist was not used as fallback for inserting
new albums in case album artist is not available. This made tracks
with no album artist create albums with empty artists.

Reviewers: mgallien

Reviewed By: mgallien

Differential Revision: https://phabricator.kde.org/D20531
parent bc1c9957
This diff is collapsed.
......@@ -4763,6 +4763,9 @@ qulonglong DatabaseInterface::insertAlbum(const QString &title, const QString &a
if (!albumArtist.isEmpty()) {
insertArtist(albumArtist);
d->mInsertAlbumQuery.bindValue(QStringLiteral(":albumArtist"), albumArtist);
} else if (!trackArtist.isEmpty()) {
insertArtist(trackArtist);
d->mInsertAlbumQuery.bindValue(QStringLiteral(":albumArtist"), trackArtist);
} else {
d->mInsertAlbumQuery.bindValue(QStringLiteral(":albumArtist"), {});
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment