Israeli Bank Importer - v1.44.5
    Preparing search index...

    Races a promise against a timeout, rejecting with TimeoutError if exceeded.

    Implements

    Index
    • Wraps a promise with a deadline, rejecting if the deadline is exceeded.

      Type Parameters

      • T

      Parameters

      • promise: Promise<T>

        The async operation to time-box.

      • timeoutMs: number

        Maximum allowed duration in milliseconds.

      • operationName: string

        Label used in the TimeoutError message.

      Returns Promise<T>

      The resolved value of the original promise if it completes in time.