Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Date.toLocaleString returns an unexpected result when called in Snap #2233

Closed
FrederikBolding opened this issue Feb 29, 2024 · 0 comments · Fixed by #2234
Closed

Date.toLocaleString returns an unexpected result when called in Snap #2233

FrederikBolding opened this issue Feb 29, 2024 · 0 comments · Fixed by #2234
Assignees

Comments

@FrederikBolding
Copy link
Member

FrederikBolding commented Feb 29, 2024

        const now = new Date().toLocaleString(
          'en-us',
          {
            year: 'numeric',
            month: '2-digit',
            day: "2-digit",
          });

// now : Thu Feb 22 2024 16:08:20 GMT-0700 (Mountain Standard Time)

@FrederikBolding FrederikBolding self-assigned this Feb 29, 2024
FrederikBolding added a commit that referenced this issue Feb 29, 2024
Bumps LavaMoat packages to the latest version and reapplies our patches.

The change we are most interested in, is the disabling of
`localeTaming`. This change means that `new Date().toLocaleString()` no
longer is aliased to `toString()`.

Closes #2233

---------

Co-authored-by: MetaMask Bot <[email protected]>
benefacto pushed a commit to zenchain-protocol/zazen that referenced this issue Jul 3, 2024
Bumps LavaMoat packages to the latest version and reapplies our patches.

The change we are most interested in, is the disabling of
`localeTaming`. This change means that `new Date().toLocaleString()` no
longer is aliased to `toString()`.

Closes MetaMask/snaps#2233

---------

Co-authored-by: MetaMask Bot <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant