Removed useless imports
Refactored and corrected Date type