Skip to content

Investigate if timestamp of 48+ hours will throw error on render #3279

@compulim

Description

@compulim

Background

Charlie reported the timestamp will throw error on render.

Action items

  • Repro the issue

Investigation notes

Seems introduced in Web Chat 4.8.1 in PR #3095.

The reason why the "day before yesterday" is not working: the code is using "en-US" for date formatting. But it's not there (Unicode has no "en-US", but "en").

Need more investgation because:

  • "en-US" is not in locale database and it is correct, it should be "en" instead
    • Did we or should we normalize "en-US" to "en"?
  • When a locale is not found, there should be a fallback mechanism and not error out
  • Someone using "xx-ZZ" locale should fallback to "en"

[Bug]

Metadata

Metadata

Assignees

Labels

bugIndicates an unexpected problem or an unintended behavior.external-omnichannel

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions