mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-01-17 22:38:33 +01:00
be careful
This commit is contained in:
parent
de508c049b
commit
ea69fe158a
@ -196,6 +196,9 @@ CollectionItem::playlistDeletedInternal( SourceTreeItem* parent, const T& p )
|
||||
if( parent->children().isEmpty() && parent->parent() ) // Don't leave an empty Playlist or Station category
|
||||
{
|
||||
int idx = parent->parent()->children().indexOf( parent );
|
||||
if( idx < 0 )
|
||||
return;
|
||||
|
||||
parent->parent()->beginRowsRemoved( idx, idx );
|
||||
parent->parent()->removeChild( parent );
|
||||
parent->parent()->endRowsRemoved();
|
||||
|
Loading…
x
Reference in New Issue
Block a user