Skip to content
This repository has been archived by the owner on May 22, 2021. It is now read-only.

Commit

Permalink
Merge pull request #433 from pdehaan/issue-429
Browse files Browse the repository at this point in the history
Prevent download button from being clicked multiple times
  • Loading branch information
dannycoates authored Aug 4, 2017
2 parents 0f77b6d + 2f9372e commit 44ea075
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions frontend/src/download.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ $(document).ready(function() {
});
$('#download-btn').click(download);
function download() {
// Disable the download button to avoid accidental double clicks.
$('#download-btn').attr('disabled', 'disabled');

storage.totalDownloads += 1;

const fileReceiver = new FileReceiver();
Expand Down

0 comments on commit 44ea075

Please sign in to comment.