aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorMango0x45 <thomasvoss@live.com> 2021-02-03 18:28:06 +0100
committerMango0x45 <thomasvoss@live.com> 2021-02-03 18:28:06 +0100
commitdd2a3adb56242b2d2294f8eb074804022a5edfac (patch)
tree2257f4cb4d85b0286560e70480ab0bb62e44f936
parent6022f1333cec4f10da7484e2e7dc78a54e447ac8 (diff)
Fix milliseconds
-rw-r--r--main.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/main.js b/main.js
index d6394a5..ee1437d 100644
--- a/main.js
+++ b/main.js
@@ -40,6 +40,11 @@ function time_format(t)
ret += m + ":" + (s < 10 ? "0" : "");
ret += s;
+ /* Milliseconds */
+ const st = t.toString();
+ if (!isNaN(t) && st.indexOf(".") != -1)
+ ret += "." + st.split(".")[1];
+
return ret;
}