Fixing bug in window.chat.setupTime
Problem: "#chatinput time" use "toLocaleTimeString().slice(0, 5)" to get time, but hh:mm not always at 0-5 in all locale Fix: Use "toISOString().slice(11, 16)" to get time for "#chatinput time"
This commit is contained in:
@ -616,7 +616,7 @@ window.chat.setupTime = function() {
|
||||
var updateTime = function() {
|
||||
if(window.isIdle()) return;
|
||||
var d = new Date();
|
||||
inputTime.text(d.toLocaleTimeString().slice(0, 5));
|
||||
inputTime.text(d.toISOString().slice(11, 16));
|
||||
// update ON the minute (1ms after)
|
||||
setTimeout(updateTime, (60 - d.getSeconds()) * 1000 + 1);
|
||||
};
|
||||
|
Reference in New Issue
Block a user