Open yahooooza opened 11 months ago
Yes, facing the same issue. Getting 2023-11-01 00:00:00.000 instead of 2023-10-31 11:59:59.999.
DateTime.now().endOf(Unit.month).dateTime;
Tested on : Chrome Version 117.0.5938.149 (Official Build) (arm64)
Flutter 3.13.7 • channel stable • https://github.com/flutter/flutter.git Framework • revision 2f708eb839 (7 days ago) • 2023-10-09 09:58:08 -0500 Engine • revision a794cf2681 Tools • Dart 3.1.3 • DevTools 2.25.0
On MacMini
Describe the bug
The method endOf is decribed as giving the last microsecond that belong to the unit given. In Chrome somehow this doesn't work. And therefore the function isSame doesnt work as expected either.
How to reproduce the bug
Her an Example to show the Bug:
What is the expected behavior
For the date 2023-01-25, endOf for the unit Unit.month should return 2023-01-25T23:59.59.999999. Also if comparing the Jiffy Dates 2023-01-25 and 2023-02-01 isSame should return false.
Screenshots
Additional information
Tested on : Chrome 117.0.5938.92 Flutter 3.13.4 On Linux In Debug Mode and as Release Version deployed on a server