found bug in date converter- added if statements as possible fix