aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/js/base64.js
diff options
context:
space:
mode:
authorPeter Wu2014-07-25 23:28:21 +0200
committerPim van den Berg2014-08-02 12:29:32 +0200
commitb6be82b8edefa452e72ed53391971e53d9dccf83 (patch)
tree01a33ac72f6ef7e6e5c607238bc5e4dd3a8751fe /js/base64.js
parentsupport php versions without json support and show a warning message (diff)
downloadapt-panopticon_cgp-b6be82b8edefa452e72ed53391971e53d9dccf83.zip
apt-panopticon_cgp-b6be82b8edefa452e72ed53391971e53d9dccf83.tar.gz
apt-panopticon_cgp-b6be82b8edefa452e72ed53391971e53d9dccf83.tar.bz2
apt-panopticon_cgp-b6be82b8edefa452e72ed53391971e53d9dccf83.tar.xz
jsrrdgraph: Fixed jshint warnings/errors
Many fall in the category missing semicolon, but there are legitimate bugs (like throwing an error with an undefined variable, using isInfinite instead of !isFinite or fabs instead of Math.abs). At some places, I moved the variable declarations to avoid duplicate definition warnings. Redundant breaks have been removed (after return / throw). Global variables were implicitly defined in RrdDataFile (which caught my attention) and Base64, these have been made local. Also fixed some whitespace errors. Yay, the consistency. Not all (style) issues are fixed.
Diffstat (limited to 'js/base64.js')
-rw-r--r--js/base64.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/js/base64.js b/js/base64.js
index 7d9536a..4cd5c96 100644
--- a/js/base64.js
+++ b/js/base64.js
@@ -113,7 +113,8 @@ var Base64 = {
113 _utf8_decode : function (utftext) { 113 _utf8_decode : function (utftext) {
114 var string = ""; 114 var string = "";
115 var i = 0; 115 var i = 0;
116 var c = c1 = c2 = 0; 116 var c, c1, c2, c3;
117 c = c1 = c2 = 0;
117 118
118 while ( i < utftext.length ) { 119 while ( i < utftext.length ) {
119 120
@@ -140,4 +141,4 @@ var Base64 = {
140 return string; 141 return string;
141 } 142 }
142 143
143} 144};