nextMonth method

MonthAndYear nextMonth()

Implementation

MonthAndYear nextMonth() {
  if (month == 12) {
    return MonthAndYear(
      month: 1,
      year: year + 1,
    );
  }

  return MonthAndYear(
    month: month + 1,
    year: year,
  );
}