fix: remove coins not supported by ciphertrace
This commit is contained in:
parent
708dea736d
commit
e798be94ae
3 changed files with 3 additions and 12 deletions
|
|
@ -126,10 +126,7 @@ function checkBlockchainStatus (cryptoCode) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function getTxHashesByAddress (cryptoCode, address) {
|
function getTxHashesByAddress (cryptoCode, address) {
|
||||||
checkCryptoCode(cryptoCode)
|
throw new Error(`Transactions hash retrieval is not implemented for this coin!`)
|
||||||
.then(() => fetch('listreceivedbyaddress', [0, true, true, true, address]))
|
|
||||||
.then(txsByAddress => Promise.all(_.forEach(id => fetch('getrawtransaction', [id]), _.head(txsByAddress).txids)))
|
|
||||||
.then(_.map(({ hash }) => hash))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
|
|
||||||
|
|
@ -236,11 +236,7 @@ function checkBlockchainStatus (cryptoCode) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function getTxHashesByAddress (cryptoCode, address) {
|
function getTxHashesByAddress (cryptoCode, address) {
|
||||||
checkCryptoCode(cryptoCode)
|
throw new Error(`Transactions hash retrieval is not implemented for this coin!`)
|
||||||
.then(() => refreshWallet())
|
|
||||||
.then(() => fetch('get_address_index', { address: address }))
|
|
||||||
.then(addressRes => fetch('get_transfers', { in: true, pool: true, pending: true, account_index: addressRes.index.major, address_indices: [addressRes.index.minor] }))
|
|
||||||
.then(_.map(({ txid }) => txid))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
|
|
||||||
|
|
@ -152,9 +152,7 @@ function checkBlockchainStatus (cryptoCode) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function getTxHashesByAddress (cryptoCode, address) {
|
function getTxHashesByAddress (cryptoCode, address) {
|
||||||
checkCryptoCode(cryptoCode)
|
throw new Error(`Transactions hash retrieval is not implemented for this coin!`)
|
||||||
.then(() => fetch('getaddresstxids', [address]))
|
|
||||||
.then(_.mapKeys(() => 'txid'))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue