fixed crash in dateprovider