I'm very thankful for your project and I'm using it. However I found one small problem. Basically, at least with my timezone "EDT" (Eastern Daylight Saving Time), localTimezone_() returns "EDT", but when Gmail.Utils.formatDate calls Utilities.formatDate(message.getDate(), timezone, format), it has problems taking "EDT" as the timezone input, and end up using "GMT" instead as the timezone. Therefore it ends up returning a date formatted with GMT timezone, not local timezone. While the format string is such that it still says "EDT", therefore the datetime string is wrong. (here)
I did find that (a hack) if I use Utilities.formatDate() and it would return "America/New_York", and with that as the timezone input, it gets Utilities.formatDate() working correctly. Hence the below work-around:
Hi @mikegreiling
I'm very thankful for your project and I'm using it. However I found one small problem. Basically, at least with my timezone "EDT" (Eastern Daylight Saving Time),
localTimezone_()
returns "EDT", but whenGmail.Utils.formatDate
callsUtilities.formatDate(message.getDate(), timezone, format)
, it has problems taking "EDT" as the timezone input, and end up using "GMT" instead as the timezone. Therefore it ends up returning a date formatted with GMT timezone, not local timezone. While the format string is such that it still says "EDT", therefore the datetime string is wrong. (here)I did find that (a hack) if I use
Utilities.formatDate()
and it would return "America/New_York", and with that as the timezone input, it gets Utilities.formatDate() working correctly. Hence the below work-around:I'm using my work-around to replace
Gmail.Utils.formatDate
, but want to report this issue. Thx!