function getYear(dirtyDate) {
  __WEBPACK_IMPORTED_MODULE_1__lib_requiredArgs_index_js__["a" /* default */](1, arguments);
  var date = __WEBPACK_IMPORTED_MODULE_0__toDate_index_js__["a" /* default */](dirtyDate);
  var year = date.getFullYear();
  return year;
}
@name intervalToDuration
@category Common Helpers
@summary Convert interval to duration

@description
Convert a interval object to a duration object.

@param {Interval} interval - the interval to convert to duration

@returns {Duration} The duration Object
@throws {TypeError} Requires 2 arguments
@throws {RangeError} `start` must not be Invalid Date
@throws {RangeError} `end` must not be Invalid Date

@example
// Get the duration between January 15, 1929 and April 4, 1968.
intervalToDuration({
  start: new Date(1929, 0, 15, 12, 0, 0),
  end: new Date(1968, 3, 4, 19, 5, 0)
})
// => { years: 39, months: 2, days: 20, hours: 7, minutes: 5, seconds: 0 }