mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-15 12:51:00 +02:00
Remove mempool global
This commit is contained in:
parent
fa0359c5b3
commit
fafb381af8
8 changed files with 11 additions and 12 deletions
|
|
@ -102,7 +102,7 @@ static CTxMemPool* GetMemPool(const util::Ref& context, HTTPRequest* req)
|
|||
RESTERR(req, HTTP_NOT_FOUND, "Mempool disabled or instance not found");
|
||||
return nullptr;
|
||||
}
|
||||
return node->mempool;
|
||||
return node->mempool.get();
|
||||
}
|
||||
|
||||
static RetFormat ParseDataFormat(std::string& param, const std::string& strReq)
|
||||
|
|
@ -393,7 +393,7 @@ static bool rest_tx(const util::Ref& context, HTTPRequest* req, const std::strin
|
|||
const NodeContext* const node = GetNodeContext(context, req);
|
||||
if (!node) return false;
|
||||
uint256 hashBlock = uint256();
|
||||
const CTransactionRef tx = GetTransaction(/* block_index */ nullptr, node->mempool, hash, Params().GetConsensus(), hashBlock);
|
||||
const CTransactionRef tx = GetTransaction(/* block_index */ nullptr, node->mempool.get(), hash, Params().GetConsensus(), hashBlock);
|
||||
if (!tx) {
|
||||
return RESTERR(req, HTTP_NOT_FOUND, hashStr + " not found");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue