Skip to content

Commit

Permalink
fix: File was being deleted even if it was in queue
Browse files Browse the repository at this point in the history
  • Loading branch information
lvmasterrj authored and vicwomg committed Dec 24, 2024
1 parent 162aa3d commit 79c4000
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pikaraoke/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,8 @@ def start_song():
def delete_file():
if "song" in request.args:
song_path = request.args["song"]
if song_path in k.queue:
exists = any(item.get('file') == song_path for item in k.queue)
if exists:
flash(
"Error: Can't delete this song because it is in the current queue: " + song_path,
"is-danger",
Expand Down

0 comments on commit 79c4000

Please sign in to comment.