Skip to main content

PromiseRetryUtils

Functions

retry

PromiseRetryUtils.retry(
callbackfunction,--

Callback that returns a promise

optionsRetryOptions--

Options for retrying

) → Promise<T>

Returns a promise that will retry the given callback until it succeeds or the max attempts is reached.

Show raw api
{
    "functions": [
        {
            "name": "retry",
            "desc": "Returns a promise that will retry the given callback until it succeeds or the max attempts\nis reached.",
            "params": [
                {
                    "name": "callback",
                    "desc": "Callback that returns a promise",
                    "lua_type": "function"
                },
                {
                    "name": "options",
                    "desc": "Options for retrying",
                    "lua_type": "RetryOptions"
                }
            ],
            "returns": [
                {
                    "desc": "",
                    "lua_type": "Promise<T>"
                }
            ],
            "function_type": "static",
            "source": {
                "line": 27,
                "path": "src/promise/src/Shared/PromiseRetryUtils.lua"
            }
        }
    ],
    "properties": [],
    "types": [],
    "name": "PromiseRetryUtils",
    "desc": "",
    "source": {
        "line": 5,
        "path": "src/promise/src/Shared/PromiseRetryUtils.lua"
    }
}