Compare timestamps when deleting from playlist

Comparing only the timestamps when deleting an item from the
playlist, should remove it faster.
This commit is contained in:
Franz A. Steffek
2018-06-02 14:27:18 +02:00
parent 08ea59e759
commit 5da246f24f
2 changed files with 2 additions and 2 deletions

View File

@ -90,7 +90,7 @@ def index():
var.playlist.extend(files)
elif 'delete_music' in request.form:
for item in var.playlist:
if str(item) == request.form['delete_music']:
if str(item[2]) == request.form['delete_music']:
var.playlist.remove(item)
break
elif 'action' in request.form: