mahnunchik / mag

Mag is the streaming logger for NodeJS
https://npmjs.org/mag
MIT License
54 stars 3 forks source link

ISO formatted time #6

Open envilogger opened 8 years ago

envilogger commented 8 years ago

Hi

I found that you're using toLocaleTimeString() method to write timestamp It might cause problems in some cases (ie if different locale is set on different environments and local developers machine) So, for example, if locale is set to en-us timestamp looks like 4:32:46 PM.765 I think it's better to use ISO formatted time, ie 16:32:46.765

mahnunchik commented 8 years ago

Hi @envilogger

Yes, using toLocaleTimeString method isn't good idea. But for mag-fallback module I think it will be enough to have only time in the message. I will try to implement it using getUTC* methods.