date processing functions
clean up date functions