class Time

def days_in_year(year = current.year)

If no year is specified, it will use the current year.
Returns the number of days in the given year.
def days_in_year(year = current.year)
  days_in_month(2, year) + 337
end