UNPKG

@ledgerhq/coin-canton

Version:
11 lines 527 B
import { patchOperationWithHash } from "@ledgerhq/ledger-wallet-framework/operation"; import { broadcast as broadcastLogic } from "../common-logic"; export const broadcast = async ({ account, signedOperation, }) => { const { operation, signature } = signedOperation; const hash = await broadcastLogic(account.currency, signature); if (!hash) { throw new Error("canton: broadcast returned no transaction id"); } return patchOperationWithHash(operation, hash); }; //# sourceMappingURL=broadcast.js.map