mirror of
https://github.com/fullstack-cash/bch-api.git
synced 2026-09-21 16:52:04 -07:00
fix(txDetails): Adding additional metadata to GET slp/txDetails
This commit is contained in:
@@ -1251,6 +1251,8 @@ class Slp {
|
|||||||
const tokenRes = await _this.axios.request(opt)
|
const tokenRes = await _this.axios.request(opt)
|
||||||
// console.log(`tokenRes: ${util.inspect(tokenRes)}`)
|
// console.log(`tokenRes: ${util.inspect(tokenRes)}`)
|
||||||
|
|
||||||
|
// Return 'not found' error if both the confirmed and unconfirmed
|
||||||
|
// collections are empty.
|
||||||
if (tokenRes.data.c.length === 0 && tokenRes.data.u.length === 0) {
|
if (tokenRes.data.c.length === 0 && tokenRes.data.u.length === 0) {
|
||||||
res.status(404)
|
res.status(404)
|
||||||
return res.json({ error: 'TXID not found' })
|
return res.json({ error: 'TXID not found' })
|
||||||
@@ -1437,9 +1439,9 @@ class Slp {
|
|||||||
sendOutputs.push(string.toString())
|
sendOutputs.push(string.toString())
|
||||||
})
|
})
|
||||||
|
|
||||||
// Because you are not using insight, you do not get the sending addresses from an indexer
|
// Because you are not using Insight API indexer, you do not get the
|
||||||
// or from the node
|
// sending addresses from an indexer or from the node.
|
||||||
// However, they are available from the SLPDB output
|
// However, they are available from the SLPDB output.
|
||||||
const tokenInputs = transaction.in
|
const tokenInputs = transaction.in
|
||||||
// Collect the input addresses
|
// Collect the input addresses
|
||||||
const sendInputs = []
|
const sendInputs = []
|
||||||
|
|||||||
Reference in New Issue
Block a user