We do not support coin imports
This commit is contained in:
@@ -693,7 +693,7 @@ public:
|
|||||||
|
|
||||||
bool IsMint() const
|
bool IsMint() const
|
||||||
{
|
{
|
||||||
return IsCoinImport() || IsCoinBase();
|
return IsCoinBase(); // || IsCoinImport();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool IsCoinBase() const
|
bool IsCoinBase() const
|
||||||
@@ -705,7 +705,8 @@ public:
|
|||||||
|
|
||||||
bool IsCoinImport() const
|
bool IsCoinImport() const
|
||||||
{
|
{
|
||||||
return (vin.size() == 1 && vin[0].prevout.n == 10e8);
|
return false;
|
||||||
|
//return (vin.size() == 1 && vin[0].prevout.n == 10e8);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool IsPegsImport() const
|
bool IsPegsImport() const
|
||||||
|
|||||||
@@ -146,31 +146,7 @@ void TxToJSONExpanded(const CTransaction& tx, const uint256 hashBlock, UniValue&
|
|||||||
UniValue in(UniValue::VOBJ);
|
UniValue in(UniValue::VOBJ);
|
||||||
if (tx.IsCoinBase()) {
|
if (tx.IsCoinBase()) {
|
||||||
in.push_back(Pair("coinbase", HexStr(txin.scriptSig.begin(), txin.scriptSig.end())));
|
in.push_back(Pair("coinbase", HexStr(txin.scriptSig.begin(), txin.scriptSig.end())));
|
||||||
}
|
} else {
|
||||||
/* else if (tx.IsCoinImport() && txin.prevout.n==10e8) {
|
|
||||||
in.push_back(Pair("is_import", "1"));
|
|
||||||
ImportProof proof; CTransaction burnTx; std::vector<CTxOut> payouts; CTxDestination importaddress;
|
|
||||||
if (UnmarshalImportTx(tx, proof, burnTx, payouts))
|
|
||||||
{
|
|
||||||
if (burnTx.vout.size() == 0)
|
|
||||||
continue;
|
|
||||||
in.push_back(Pair("txid", burnTx.GetHash().ToString()));
|
|
||||||
in.push_back(Pair("value", ValueFromAmount(burnTx.vout.back().nValue)));
|
|
||||||
in.push_back(Pair("valueSat", burnTx.vout.back().nValue));
|
|
||||||
// extract op_return to get burn source chain.
|
|
||||||
std::vector<uint8_t> burnOpret; std::string targetSymbol; uint32_t targetCCid; uint256 payoutsHash; std::vector<uint8_t>rawproof;
|
|
||||||
if (UnmarshalBurnTx(burnTx, targetSymbol, &targetCCid, payoutsHash, rawproof))
|
|
||||||
{
|
|
||||||
if (rawproof.size() > 0)
|
|
||||||
{
|
|
||||||
std::string sourceSymbol;
|
|
||||||
E_UNMARSHAL(rawproof, ss >> sourceSymbol);
|
|
||||||
in.push_back(Pair("address", "IMP-" + sourceSymbol + "-" + burnTx.GetHash().ToString()));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} */
|
|
||||||
else {
|
|
||||||
in.push_back(Pair("txid", txin.prevout.hash.GetHex()));
|
in.push_back(Pair("txid", txin.prevout.hash.GetHex()));
|
||||||
in.push_back(Pair("vout", (int64_t)txin.prevout.n));
|
in.push_back(Pair("vout", (int64_t)txin.prevout.n));
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user