@umbraco-cms/backoffice

    Function tryExecuteAndNotify

    • Make a request and notify the user of any errors. This function is a wrapper around the tryExecute function and will notify the user of any errors. It is useful for making requests where you want to handle errors in a consistent way.

      Type Parameters

      • T

        The type of the response data.

      Parameters

      • host: UmbControllerHost

        The host to use for the request.

      • resource: Promise<T>

        The resource to request.

      Returns Promise<UmbApiResponse<T>>

      A promise that resolves with the response data or rejects with an error.

      Use the tryExecute function instead and handle the error in the caller. This function is kept for backwards compatibility and will be removed in a future version.

    MMNEPVFCICPMFPCPTTAAATR