From 64bc5c47da06fbb6b638f2c95e44f081089fc7c3 Mon Sep 17 00:00:00 2001 From: Juuso Lapinlampi Date: Sun, 27 Sep 2015 15:34:27 +0000 Subject: Fix JavaScript units[] array coding style Reduces confusion and improves readability, despite not having yet agreed on which JavaScript style guide to use. --- js/cheesesteak.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'js/cheesesteak.js') diff --git a/js/cheesesteak.js b/js/cheesesteak.js index 821b9cd..a3cf991 100644 --- a/js/cheesesteak.js +++ b/js/cheesesteak.js @@ -66,8 +66,8 @@ /* Utility to convert bytes into human units */ var humanSize = { get: function humanSize() { - var units = ["B", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", - "YiB" + var units = [ + "B", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB" ]; var e = Math.floor(Math.log(this.size) / Math.log(1024)); return (this.size / Math.pow(1024, e)).toFixed(2) + " " + units[e]; -- cgit v1.2.3