formatDate needs class or integer as a parameter