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

Asia/Katmandu is not a valid timezone #603

Open
Summonshr opened this issue Sep 12, 2024 · 1 comment
Open

Asia/Katmandu is not a valid timezone #603

Summonshr opened this issue Sep 12, 2024 · 1 comment

Comments

@Summonshr
Copy link

I am from nepal. Somehow, the timezone used is Asia/Katmandu but in server we have Asia/Kathmandu. I am not sure what to do about. Fix in front-end or back-end. The Intl.DateTimeFormat().resolvedOptions().timeZone api used gives 'Asia/Katmandu' which is not right as per server valid timezones.

image

@pratikkuikel
Copy link

@Summonshr This is actually not an issue with this project or the php.
Php recognizes Asia/Kathmandu as timezone and not Asia/Katmandu resulting in invalid timezone.

It's actually an issue of IANA.
moment/moment-timezone#754
moment/moment-timezone#159
https://www.iana.org/time-zones

I have verified that the current timezone database of IANA has Asia/Kathmandu.
This could be due to current nodejs running in your or my system not having latest timezone db updates.
IDK

Current workaround could be adding this to the file layouts/app.blade.php before sending post request to the server.

if (timezone === 'Asia/Katmandu') {
    timezone = 'Asia/Kathmandu';
}

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.

2 participants