Problem/Motivation
Currently, if you render tokens for message, all timestamps are rendered by using current user. With multilingual (and multi-timezoned) this becomes a bit tricky.
In scenario, where there's mail including datetime token being sent to recipient from queue, and the queue is ran in cron, the current user is anonymous, which does not have timezone. This leads in situation where the datetime is default timezone.
The solution for above is to use `account_switcher` service when handling the queue to set current user to be the recipient.
However, if you like to let the user know what timezone was actually used for the timestamps, you would probably add something like
All times are shown as timezone of [current-user:timezone]
And for some reason, this isn't yet possible.
Proposed resolution
Adds a "timezone" user token, which gets either the user's timezone or the default time zone.
Remaining tasks
- Edit the change record for language and code examples following other change records
User interface changes
Adds a new token.
Adds a new translatable string: "The timezone of the user account."
API changes
N/A
Data model changes
N/A
Release notes snippet