commit 75d5913f7ab40e27a9694d85c2e33dc3cb613bff
parent 727fb832bdcdf9f11e5c73c751dd3bc41d4ceb94
Author: Timo A. Hummel <timo@netraver.de>
Date: Thu, 9 Jun 2011 03:32:48 +0200
Fixed jslint warnings
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/frontend/js/PartDB2.js b/frontend/js/PartDB2.js
@@ -278,8 +278,8 @@ PartDB2.getMaxUploadSize = function () {
PartDB2.bytesToSize = function (bytes) {
var sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB'];
- if (bytes == 0) return 'n/a';
- var i = parseInt(Math.floor(Math.log(bytes) / Math.log(1024)));
+ if (bytes === 0) return 'n/a';
+ var i = parseInt(Math.floor(Math.log(bytes) / Math.log(1024)),10);
return Math.round(bytes / Math.pow(1024, i), 2) + ' ' + sizes[i];
};