Skip to content

Commit

Permalink
Remove unnecessary code
Browse files Browse the repository at this point in the history
  • Loading branch information
wellkochi authored Mar 16, 2020
1 parent 5d93ce3 commit 3ac7a58
Showing 1 changed file with 0 additions and 43 deletions.
43 changes: 0 additions & 43 deletions app/sign.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,45 +11,6 @@ const bip39 = require('bip39');
const bitgojs = require('bitgo');
let bitgo;

// const utxoNetworks = {
// btc: utxoLib.networks.bitcoin,
// ltc: utxoLib.networks.litecoin,
// bch: utxoLib.networks.bitcoincash,
// bsv: utxoLib.networks.bitcoinsv,
// zec: utxoLib.networks.zcash,
// dash: utxoLib.networks.dash,
// tltc: utxoLib.networks.litecoin,
// tbtc: utxoLib.networks.testnet,
// tbch: utxoLib.networks.bitcoincashTestnet,
// tbsv: utxoLib.networks.bitcoinsvTestnet,
// tzec: utxoLib.networks.zcashTest,
// tdash: utxoLib.networks.dashTest,
// };

// const coinDecimals = {
// btc: 8,
// eth: 18,
// eos: 4,
// trx: 6,
// xrp: 6,
// bch: 8,
// bsv: 8,
// ltc: 8,
// zec: 8,
// dash: 8,
// xlm: 7,
// tbtc: 8,
// teth: 18,
// teos: 4,
// ttrx: 6,
// txrp: 6,
// tltc: 8,
// txlm: 7,
// tbch: 8,
// tbsv: 8,
// tzec: 8,
// tdash: 8,
// };

const BCH_COINS = ['bch', 'tbch', 'bsv', 'tbsv'];
const TEN = new BN(10);
Expand Down Expand Up @@ -132,8 +93,6 @@ const getBackupSigningKey = function(key, expectedXpub) {

const handleSignUtxo = function(recoveryRequest, key, skipConfirm) {

// const network = utxoNetworks[recoveryRequest.coin];
// const decimals = coinDecimals[recoveryRequest.coin];
const network = statics.coins.get[recoveryRequest.coin].network;
const decimals = statics.coins.get[recoveryRequest.coin].decimalPlaces;

Expand Down Expand Up @@ -235,7 +194,6 @@ const signEthTx = function(recoveryRequest, key, skipConfirm, isToken) {

// if request is for ETH, need to correct the amount decimals.
if (!isToken) {
// const decimals = coinDecimals[recoveryRequest.coin];
const decimals = statics.coins.get[recoveryRequest.coin].decimalPlaces;

outputs[0].amount = outputs[0].amount.div(TEN.pow(decimals));
Expand Down Expand Up @@ -310,7 +268,6 @@ const handleSignXrp = function(recoveryRequest, key, skipConfirm) {

const txHex = getTransactionHexFromRequest(recoveryRequest);

// const decimals = coinDecimals[recoveryRequest.coin];
const decimals = statics.coins.get[recoveryRequest.coin].decimalPlaces;
const transaction = rippleParse.decode(txHex);

Expand Down

0 comments on commit 3ac7a58

Please sign in to comment.