Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: network choice
Browse files Browse the repository at this point in the history
meeh0w committed Oct 23, 2024
1 parent d468a2e commit 576e024
Showing 2 changed files with 2 additions and 14 deletions.
Original file line number Diff line number Diff line change
@@ -73,13 +73,7 @@ export class AvalancheSendTransactionHandler extends DAppRequestHandler<
}),
};
}
const network = await this.networkService.getNetwork(scope);
if (!network) {
return {
...request,
error: ethErrors.rpc.invalidParams('Unknown network'),
};
}
const network = await this.networkService.getAvalancheNetworkXP();
const vm = Avalanche.getVmByChainAlias(chainAlias);
const txBytes = utils.hexToBuffer(transactionHex);
const provider = await this.networkService.getAvalanceProviderXP();
Original file line number Diff line number Diff line change
@@ -80,13 +80,7 @@ export class AvalancheSignTransactionHandler extends DAppRequestHandler<TxParams

const tx = utils.unpackWithManager(vm, txBytes) as avaxSerial.AvaxTx;

const network = await this.networkService.getNetwork(scope);
if (!network) {
return {
...request,
error: ethErrors.rpc.invalidParams('Unknown network'),
};
}
const network = await this.networkService.getAvalancheNetworkXP();
const providedUtxos = getProvidedUtxos({
utxoHexes: providedUtxoHexes,
vm,

0 comments on commit 576e024

Please sign in to comment.