def failed

cswap-bend-cli@0.1.0.0 · cmd.bend:30

import cswap-bend-cli@0.1.0.0/cmd.bend as Cmd
import Base

30# `json` picks the envelope or the text error.
31def failed(json: Bool, kind: String, msg: String) -> Out:
32  match json:
33    case True{}:
34      json_fail(kind, msg)
35    case False{}:
36      fail(msg)

Uses (5)

Used by (5)