pub fn pred_day(date: NaiveDate) -> NaiveDate
Calculates a date with the previous day based on the given date.