Open Summonshr opened 2 months ago
@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. https://github.com/moment/moment-timezone/issues/754 https://github.com/moment/moment-timezone/issues/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';
}
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.