Skip to content

Commit

Permalink
Merge pull request FabricLabs#96 from naterchrdsn/master
Browse files Browse the repository at this point in the history
Added confirmation prompt for skipping a track
  • Loading branch information
martindale committed Feb 18, 2014
2 parents 573207f + 8be9deb commit 11aa493
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions public/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -667,8 +667,10 @@ $(window).load(function(){

$(document).on('click', '*[data-action=skip-track]', function(e) {
e.preventDefault();
soundtrack.player.pause();
$.post('/skip');
if (confirm("Are you sure you want to skip?")) {
soundtrack.player.pause();
$.post('/skip');
}
return false;
});

Expand Down

0 comments on commit 11aa493

Please sign in to comment.