summaryrefslogtreecommitdiff
path: root/js/pomf.js
diff options
context:
space:
mode:
authorJuuso Lapinlampi <wub@partyvan.eu>2015-09-27 21:22:31 +0200
committerJuuso Lapinlampi <wub@partyvan.eu>2015-09-27 21:25:38 +0200
commitf1c92f57d6a5ae01b8c67bf3f6d1189f41537339 (patch)
tree3dae85569485aa823a35c0f139372da20896b5c3 /js/pomf.js
parentc2681b55d6e6643ab113e6f0945a443793a34fab (diff)
Use individual Javascript var declarations
Thanks to ASI (Automatic Semicolon Insertion) in JavaScript, not using individual var declarations can actually cause subtle bugs. Fixes JSCS disallowMultipleVarDecl warnings using Airbnb preset. Reference: http://benalman.com/news/2012/05/multiple-var-statements-javascript/
Diffstat (limited to 'js/pomf.js')
-rw-r--r--js/pomf.js16
1 files changed, 8 insertions, 8 deletions
diff --git a/js/pomf.js b/js/pomf.js
index 5a359da..2d4ff58 100644
--- a/js/pomf.js
+++ b/js/pomf.js
@@ -23,9 +23,9 @@
/* jshint browser:true, jquery:true */
$(function() {
- var uploadInput = $('#upload-input'),
- uploadBtn = $('#upload-btn'),
- uploadFiles = $('#upload-filelist');
+ var uploadInput = $('#upload-input');
+ var uploadBtn = $('#upload-btn');
+ var uploadFiles = $('#upload-filelist');
var btnContent = '';
@@ -73,11 +73,11 @@ $(function() {
})(uploadInput);
var createRow = function(filename, size, extra) {
- var rowItem = $('<li class=file>'),
- rowName = $('<span class=file-name>'),
- rowProg = $('<div class="file-progress progress-outer">'),
- rowSize = $('<span class=file-size>'),
- rowUrl = $('<span class=file-url>');
+ var rowItem = $('<li class=file>');
+ var rowName = $('<span class=file-name>');
+ var rowProg = $('<div class="file-progress progress-outer">');
+ var rowSize = $('<span class=file-size>');
+ var rowUrl = $('<span class=file-url>');
rowItem.addClass(extra || '');