mirror of
https://gitlab.com/timvisee/send.git
synced 2025-12-06 22:20:55 +03:00
Merge pull request #433 from pdehaan/issue-429
Prevent download button from being clicked multiple times
This commit is contained in:
@@ -42,6 +42,9 @@ $(document).ready(function() {
|
|||||||
});
|
});
|
||||||
$('#download-btn').click(download);
|
$('#download-btn').click(download);
|
||||||
function download() {
|
function download() {
|
||||||
|
// Disable the download button to avoid accidental double clicks.
|
||||||
|
$('#download-btn').attr('disabled', 'disabled');
|
||||||
|
|
||||||
storage.totalDownloads += 1;
|
storage.totalDownloads += 1;
|
||||||
|
|
||||||
const fileReceiver = new FileReceiver();
|
const fileReceiver = new FileReceiver();
|
||||||
|
|||||||
Reference in New Issue
Block a user