Fix for setting up the datepicker