refactor(Angular): make NaN check in date equality cleaner