Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Parent issue wordpress-mobile/WordPress-Android#13268
This PR adjusts after/before dates based on the current timezone.
When the user selects a date range eg. 10-12th of January, they expect to see data for 10-12th in their timezone. Therefore the app needs to adjust the date range based on the current timezone of the device.
For example
2020-01-10T00:00:00+00:00 becomes 2020-01-09T21:00:00+00:00 when the device's timezone is GMT+3. The user selected "10th of January" which is "9th of January 21pm" in GMT+0 (server timezone).
To test:
Test in WPAndroid wordpress-mobile/WordPress-Android#13655