day is not a datetime object

another documentation fix as the provided sample code does not work: day is being passed to contains, but contains requires a \DateTime object. passing day.begin fixes the problem