mirror of
https://github.com/kvazar-network/kevacoin.git
synced 2025-02-04 03:04:27 +00:00
Only return hex field once in getrawtransaction
The hex is already returned in TxToUniv, no need to give it out a second independent time in getrawtransaction itself.
This commit is contained in:
parent
e526ca6284
commit
e029c6e709
@ -160,13 +160,10 @@ UniValue getrawtransaction(const JSONRPCRequest& request)
|
||||
: "No such mempool transaction. Use -txindex to enable blockchain transaction queries") +
|
||||
". Use gettransaction for wallet transactions.");
|
||||
|
||||
std::string strHex = EncodeHexTx(*tx, RPCSerializationFlags());
|
||||
|
||||
if (!fVerbose)
|
||||
return strHex;
|
||||
return EncodeHexTx(*tx, RPCSerializationFlags());
|
||||
|
||||
UniValue result(UniValue::VOBJ);
|
||||
result.push_back(Pair("hex", strHex));
|
||||
TxToJSON(*tx, hashBlock, result);
|
||||
return result;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user