From f5f07fd058e645b6c6c53ee7cda05f82e07e3211 Mon Sep 17 00:00:00 2001 From: Et0h Date: Sat, 30 Jan 2016 13:14:43 +0000 Subject: [PATCH] Add new playlist items to end --- syncplay/ui/gui.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/syncplay/ui/gui.py b/syncplay/ui/gui.py index c6d66be..5633634 100644 --- a/syncplay/ui/gui.py +++ b/syncplay/ui/gui.py @@ -1437,14 +1437,14 @@ class MainWindow(QtGui.QMainWindow): self.removePlaylistNote() filename = os.path.basename(filePath) if self.noPlaylistDuplicates(filename): - if self.playlist == -1: + if self.playlist == -1 or index == -1: self.playlist.addItem(filename) else: self.playlist.insertItem(index, filename) elif isURL(filePath): self.removePlaylistNote() if self.noPlaylistDuplicates(filePath): - if index == -1: + if self.playlist == -1 or index == -1: self.playlist.addItem(filePath) else: self.playlist.insertItem(index, filePath)