Options
All
  • Public
  • Public/Protected
  • All
Menu

Module utils/ErrorUtils

Functions

throwIf

  • throwIf(guard: boolean, message: string): guard
  • Throws an Error if the guard is true.

    Parameters

    • guard: boolean
    • message: string

    Returns guard

throwIfUndefined

  • throwIfUndefined<T>(object: T | undefined, message: string): object
  • Throws an Error if the object is undefined.

    Type parameters

    • T

    Parameters

    • object: T | undefined
    • message: string

    Returns object