1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-07-31 19:30:21 +02:00

dont crash when dropping an item with no album to album

This commit is contained in:
Michael Zanetti
2011-08-27 20:36:27 +02:00
parent f39a982e00
commit 49373bdfd0

View File

@@ -477,6 +477,10 @@ DropJob::getAlbum(const QString &artist, const QString &album)
{
artist_ptr artistPtr = Artist::get( artist );
album_ptr albumPtr = Album::get( artistPtr, album );
if ( albumPtr.isNull() )
return QList< query_ptr >();
if ( albumPtr->tracks().isEmpty() )
{
connect( albumPtr.data(), SIGNAL( tracksAdded( QList<Tomahawk::query_ptr> ) ),