@ledgerhq/coin-canton
Version:
14 lines • 602 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.broadcast = broadcast;
const gateway_1 = require("../../network/gateway");
const gateway_2 = require("../../network/gateway");
async function broadcast(currency, signedTx) {
const parsed = JSON.parse(signedTx);
const [sig, party] = parsed.signature.split("__PARTY__");
if ((0, gateway_1.isGatewayEnabled)(currency))
return (await (0, gateway_2.submit)(currency, party, parsed.serialized, sig)).update_id;
else
throw new Error("Not implemented");
}
//# sourceMappingURL=broadcast.js.map