I am using luxon for generating timezone specific dates.
Here are the outputs I am getting
startStr 2021-11-14 12:00:00 am
startTimeObj 2021-11-13T18:00:00.000Z
endStr 2021-11-14 08:00:00 am
endTimeObj 2021-11-14T14:00:00.000Z
Here is my code to convert the dates
return DateTime.fromFormat(startStr, 'yyyy-MM-dd tt', {zone: 'Asia/Dhaka', setZone: true}).toJSDate();
for startStr it is working properly. As the timezone provided is 6hours ahead it is showing 18:00:00.
But for endStr it is giving wrong output. I am guessing it is ignoring am/pm. Because the output should have been T02:00:00 but instead its showing T14:00
interestingly, it works perfectly in my local mac device. Getting wrong values in the server