const validateTimeout = (value) => {
  const min = 1000;
  const max = 300000;

  const isValid = +value ? +value >= min && +value <= max : false;

  return {
    isValid,
    error: !isValid ? `Accept from ${min} to ${max}` : '',
  };
};

export default { validateTimeout };
