switch from using strings to dates