get different values from date picker

the case is that the user enters the date by the date picker widget for two localized date attributes but when we debug the code we saw that one of the dates is got minus one day. there is no event or any change that affects the value that we got from the widget.
1 answers

That sounds like a timezone issue. It’s being used as a localized date in one place, but non localized / UTC somewhere else. Check you are consistent wherever that date is used.