Converting ios expiry and rails expiry dates to Date for comparison.