diff options
author | Mango0x45 <thomasvoss@live.com> | 2021-02-03 18:28:06 +0100 |
---|---|---|
committer | Mango0x45 <thomasvoss@live.com> | 2021-02-03 18:28:06 +0100 |
commit | dd2a3adb56242b2d2294f8eb074804022a5edfac (patch) | |
tree | 2257f4cb4d85b0286560e70480ab0bb62e44f936 | |
parent | 6022f1333cec4f10da7484e2e7dc78a54e447ac8 (diff) |
Fix milliseconds
-rw-r--r-- | main.js | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -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; } |