I'm trying to get the last monday before a specified date.
I got the date from a query and the returned date is nov 21.
But in the log I got nov 20, I don't understand why, any guidance ?
And in the database :
If I use :
var maxDate = new Date();
My function works perfectly.