Moved try-catch to getIDate method