index.js
function to24Hour(time) {
        var meridiem = time.meridiem || time.meridian;
        return (meridiem === 'am' ? 0 : 12) + (time.hour % 12);
    }
function to24Hour(time) {
        var meridiem = time.meridiem || time.meridian;
        return (meridiem === 'am' ? 0 : 12) + (time.hour % 12);
    }
function to24Hour ( time ) { var meridiem = time . meridiem || time . meridian ; return ( meridiem === 'am' ? 0 : 12 ) + ( time . hour % 12 ) ; }
Convert 12-hour time to 24-hour format.

@param {object} time Time object
@param {number} time.hour Hour to convert (1-12)
@param {string} time.meridiem Hour meridiem (am/pm). 'time.meridian' is
supported for backwards compatibility.
@return {number}
Convert 12 - hour time to 24 - hour format .