UNPKG

galeforce-tmp-sea

Version:

A customizable, promise-based, and command-oriented TypeScript library for the Riot Games API.

27 lines 1.06 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.TakesAccountId = void 0; /** * A mixin for the `.accountId()` method. * @template TBase The type of the object inside. Inferred from the `Base` parameter. * @param Base The target class. */ function TakesAccountId(Base) { return class extends Base { /** * Modifies the **accountId** associated with the Action object it is called from. * Note that associated runtime type checks are performed to ensure that * the provided account ID conforms to Riot specifications. * @param accountId The accountId to update the calling Action object with. * @throws Will throw an error if an invalid accountId or the provided * `region` fails the runtime type check. */ accountId(accountId) { this.payload.accountId = accountId; this.accountId = undefined; return this; } }; } exports.TakesAccountId = TakesAccountId; //# sourceMappingURL=account-id.js.map