mirror of
https://git.wownero.com/wownero/onion-wownero-blockchain-explorer.git
synced 2024-08-15 00:33:12 +00:00
sort txpool txs
This commit is contained in:
parent
ce6f81fd2a
commit
77d2a98e2f
1 changed files with 12 additions and 0 deletions
|
@ -124,6 +124,18 @@ MempoolStatus::read_mempool()
|
||||||
|
|
||||||
(void) pool_key_image_info;
|
(void) pool_key_image_info;
|
||||||
|
|
||||||
|
// sort txpool txs
|
||||||
|
|
||||||
|
// mempool txs are not sorted base on their arival time,
|
||||||
|
// so we sort it here.
|
||||||
|
|
||||||
|
std::sort(mempool_tx_info.begin(), mempool_tx_info.end(),
|
||||||
|
[](tx_info& t1, tx_info& t2)
|
||||||
|
{
|
||||||
|
return t1.receive_time > t2.receive_time;
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
// if dont have tx_blob member, construct tx
|
// if dont have tx_blob member, construct tx
|
||||||
// from json obtained from the rpc call
|
// from json obtained from the rpc call
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue