summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorJuuso Lapinlampi <wub@partyvan.eu>2015-10-09 15:59:32 +0200
committerJuuso Lapinlampi <wub@partyvan.eu>2015-10-09 16:00:31 +0200
commit59502c86ceba164c3ccf1a7fa58bf33560157d2b (patch)
treebb440553ac6fa6452823aa5b0d625f158478407f /js
parentbcfadb7deb7c8930df3a5142d43097391f4e9fa1 (diff)
Lint pomf.js ID length to > 2 characters
Fixes ESLint id-length errors using airbnb/legacy config. Some arguments were also unused, so this will also avoid introducing new no-unused-vars lint errors.
Diffstat (limited to 'js')
-rw-r--r--js/pomf.js22
1 files changed, 11 insertions, 11 deletions
diff --git a/js/pomf.js b/js/pomf.js
index a108c4b..0e2ecee 100644
--- a/js/pomf.js
+++ b/js/pomf.js
@@ -36,20 +36,20 @@ $(function() {
$uploadBtn.cabinet($uploadInput);
- $uploadBtn.on('dragenter', function(e) {
- if (this === e.target) {
+ $uploadBtn.on('dragenter', function(evt) {
+ if (this === evt.target) {
$(this).addClass('drop');
$btnContent = $(this).html();
$(this).html('Drop it here~');
}
});
- $uploadBtn.on('drop', function(e) {
+ $uploadBtn.on('drop', function() {
$(this).trigger('dragleave');
});
- $uploadBtn.on('dragleave', function(e) {
- var node = e.target;
+ $uploadBtn.on('dragleave', function(evt) {
+ var node = evt.target;
do {
if (node === this) {
$(this).removeClass('drop');
@@ -92,7 +92,7 @@ $(function() {
return $rowItem;
};
- $uploadBtn.on('change', function(e) {
+ $uploadBtn.on('change', function() {
$uploadFiles.empty().removeClass('error completed');
var files = $uploadInput[0].filelist;
@@ -127,7 +127,7 @@ $(function() {
});
};
- up.on('uploadprogress', function(e, files) {
+ up.on('uploadprogress', function(evt, files) {
eachRow(files, function(row, file, files) {
$('.progress-inner', row).width((file.percentUploaded * 100) + '%');
});
@@ -135,13 +135,13 @@ $(function() {
$('.progress-inner', totalRow).width((files.percentUploaded * 100) + '%');
});
- up.on('uploadcomplete', function(e) {
+ up.on('uploadcomplete', function() {
$('.progress-inner').width('100%');
$totalName.html('Grabbing URLs&hellip;');
});
- up.on('load', function(e, response) {
- switch (e.target.status) {
+ up.on('load', function(evt, response) {
+ switch (evt.target.status) {
case 200:
var res = JSON.parse(response);
if (!res.success) {
@@ -150,7 +150,7 @@ $(function() {
break;
}
- eachRow(res.files, function(row, file, files) {
+ eachRow(res.files, function(row, file) {
var $link = $('<a>');
$link.attr('href', file.url)