Fix datetime conversion for json provider