Fixed another missing NoneType check.
This commit is contained in:
parent
a9f07f0716
commit
37f1ea3ff8
1 changed files with 4 additions and 3 deletions
|
@ -92,10 +92,11 @@ class Library:
|
|||
playlist_tabs.addTab(playlist_view, playlist.title)
|
||||
|
||||
def replace_temporary_playlist(self, replace: Playlist):
|
||||
self.temporary_playlist.delete()
|
||||
if self.temporary_playlist is not None:
|
||||
self.temporary_playlist.delete()
|
||||
|
||||
if self.temporary_playlist in self.playlists:
|
||||
self.playlists.remove(self.temporary_playlist)
|
||||
if self.temporary_playlist in self.playlists:
|
||||
self.playlists.remove(self.temporary_playlist)
|
||||
|
||||
if not replace in self.playlists:
|
||||
self.playlists.append(replace)
|
||||
|
|
Loading…
Add table
Reference in a new issue