code: function getTime(d) {
    if (typeof d !== 'string' || !d) return false;
    d = d.replace(/ /g, '');
    let ptIdx = d.indexOf('.');
    if (ptIdx !== -1) {
      d = d.substr(0, ptIdx);
    }
    let tmp = d.split(':');
    if (tmp.length === 2) tmp.push('00');
    if (tmp.length !== 3) return false;
    let h = parseInt(tmp[0]),
      m = parseInt(tmp[1]),
      s = parseInt(tmp[2]);
    if (isNaN(h) || isNaN(m) || isNaN(s)) return false;
    if (h < 0 || h > 23) return false;
    if (m < 0 || m > 60) return false;
    if (s < 0 || s > 60) return false;
    if (h < 10) h = '0' + h;
    if (m < 10) m = '0' + m;
    if (s < 10) s = '0' + s;
    return {
      sum: parseInt(`${h}${m}${s}`),
      time: `${h}:${m}:${s}`
    };
  }
docs: /* Private function that builds the time, given a string  of hh:mm:ss