function parseDelay(value) {
  var millisPerSecond = 1000;
  var millis = 0;

  if (value.match(/^\d*ms$/)) {
    // Explicitly parse for milliseconds when using ms time specifier
    millis = parseInt(value, 10);
  } else {
    // Otherwise, parse for seconds, with or without time specifier then convert
    millis = parseFloat(value) * millisPerSecond;
  }

  return isNaN(millis) ? 0 : millis;
}
Given an argument (ie. from nodemonOption()), will parse and return the
equivalent millisecond value or 0 if the argument cannot be parsed

@param {String} value argument value given to the --delay option
@return {Number} millisecond equivalent of the argument