txs: fix save with new lmdb, sort to show new on top
This commit is contained in:
@@ -671,12 +671,7 @@ impl Wallet {
|
||||
}
|
||||
})
|
||||
// Sort txs by creation date and confirmation status.
|
||||
.sorted_by_key(|tx| if !tx.confirmed && (tx.tx_type == TxLogEntryType::TxSent ||
|
||||
tx.tx_type == TxLogEntryType::TxReceived) {
|
||||
-i64::MAX
|
||||
} else {
|
||||
-tx.creation_ts.timestamp()
|
||||
})
|
||||
.sorted_by_key(|tx| -tx.creation_ts.timestamp())
|
||||
// Sort to show unconfirmed at top.
|
||||
.sorted_by_key(|tx| {
|
||||
tx.confirmed || tx.tx_type == TxLogEntryType::TxReceivedCancelled ||
|
||||
|
||||
+1
-1
Submodule wallet updated: e981104085...a186e90b78
Reference in New Issue
Block a user