Function assertValidTimeInt

  • Asserts that the provided number is a valid time integer. A valid time integer is between 0 and 86399999, inclusive. If the number is not valid, an error is thrown.

    Parameters

    • n: number

      The number to be validated.

    Returns void

    Throws

    Will throw an error if the number is not a valid time integer.

    Example

    assertValidTimeInt(50000); // No error
    assertValidTimeInt(90000000); // Throws Error: 'Expected time int to be between 0 and 86399999. Got: 90000000'

Generated using TypeDoc