MCPcopy
hub / github.com/webiny/webiny-js / isFail

Method isFail

packages/sdk/src/Result.ts:58–60  ·  view source on GitHub ↗

* Checks whether the result is a failure. * * @returns `true` if the result is `fail`, otherwise `false`. * Acts as a type guard to narrow the type to a failed result.

()

Source from the content-addressed store, hash-verified

56 * Acts as a type guard to narrow the type to a failed result.
57 */
58 public isFail(): this is { _error: TError } & Result<TValue, TError> {
59 return !this._isOk;
60 }
61
62 /**
63 * Gets the value inside a successful result.

Callers 15

mapErrorMethod · 0.95
readMethod · 0.45
runMethod · 0.45
resolveMethod · 0.45
processThreatScanResultFunction · 0.45
executeMethod · 0.45
handleMethod · 0.45
executeMethod · 0.45
executeMethod · 0.45
createLanguageFunction · 0.45
languages.test.tsFile · 0.45

Calls

no outgoing calls

Tested by 8

createLanguageFunction · 0.36
createSeedPageFunction · 0.36
createAndPublishSeedPageFunction · 0.36
createSeedRedirectFunction · 0.36
createLanguageFunction · 0.36
createSeedPageFunction · 0.36
createSeedRedirectFunction · 0.36
persistTransportSettingsFunction · 0.36