fixed empty date bug