mirror of
https://github.com/logos-blockchain/lssa.git
synced 2026-08-25 06:41:13 +00:00
Merge branch 'main' into Pravdyvy/sparse-merkle-tree-storage-preparation
This commit is contained in:
@@ -133,13 +133,7 @@ impl NodeChainStore {
|
||||
serde_json::from_slice::<UTXO>(&decoded_data_curr_acc);
|
||||
if let Ok(utxo) = decoded_utxo_try {
|
||||
if &utxo.owner == acc_id {
|
||||
let input_utxo = UTXOTreeInput {
|
||||
utxo_id: utxo_id as u64,
|
||||
tx_id: tx_id as u64,
|
||||
block_id: block.block_id,
|
||||
utxo,
|
||||
};
|
||||
acc.utxo_tree.insert_item(input_utxo)?;
|
||||
acc.utxos.insert(utxo.hash, utxo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+7
-17
@@ -1062,7 +1062,7 @@ impl NodeCore {
|
||||
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr).unwrap();
|
||||
|
||||
acc.utxo_tree.get_item(new_utxo_hash)?.unwrap().clone()
|
||||
acc.utxos.get(&new_utxo_hash).unwrap().clone()
|
||||
};
|
||||
|
||||
new_utxo.log();
|
||||
@@ -1101,12 +1101,7 @@ impl NodeCore {
|
||||
.map(|new_utxo_hash| {
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr).unwrap();
|
||||
|
||||
let new_utxo = acc
|
||||
.utxo_tree
|
||||
.get_item(new_utxo_hash)
|
||||
.unwrap()
|
||||
.unwrap()
|
||||
.clone();
|
||||
let new_utxo = acc.utxos.get(&new_utxo_hash).unwrap().clone();
|
||||
|
||||
new_utxo.log();
|
||||
info!(
|
||||
@@ -1238,7 +1233,7 @@ impl NodeCore {
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr_rec).unwrap();
|
||||
acc.log();
|
||||
|
||||
acc.utxo_tree.get_item(new_utxo_hash)?.unwrap().clone()
|
||||
acc.utxos.get(&new_utxo_hash).unwrap().clone()
|
||||
};
|
||||
new_utxo.log();
|
||||
info!(
|
||||
@@ -1278,7 +1273,7 @@ impl NodeCore {
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr_rec).unwrap();
|
||||
acc.log();
|
||||
|
||||
acc.utxo_tree.get_item(new_utxo_hash)?.unwrap().clone()
|
||||
acc.utxos.get(&new_utxo_hash).unwrap().clone()
|
||||
};
|
||||
new_utxo.log();
|
||||
info!(
|
||||
@@ -1323,7 +1318,7 @@ impl NodeCore {
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr_rec).unwrap();
|
||||
acc.log();
|
||||
|
||||
let new_utxo = acc.utxo_tree.get_item(new_utxo_hash)?.unwrap().clone();
|
||||
let new_utxo = acc.utxos.get(&new_utxo_hash).unwrap().clone();
|
||||
|
||||
new_utxo.log();
|
||||
info!(
|
||||
@@ -1343,7 +1338,7 @@ impl NodeCore {
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr).unwrap();
|
||||
acc.log();
|
||||
|
||||
let new_utxo = acc.utxo_tree.get_item(new_utxo_hash)?.unwrap().clone();
|
||||
let new_utxo = acc.utxos.get(&new_utxo_hash).unwrap().clone();
|
||||
|
||||
new_utxo.log();
|
||||
info!(
|
||||
@@ -1556,12 +1551,7 @@ impl NodeCore {
|
||||
.map(|(acc_addr_rec, new_utxo_hash)| {
|
||||
let acc = write_guard.acc_map.get_mut(&acc_addr_rec).unwrap();
|
||||
|
||||
let new_utxo = acc
|
||||
.utxo_tree
|
||||
.get_item(new_utxo_hash)
|
||||
.unwrap()
|
||||
.unwrap()
|
||||
.clone();
|
||||
let new_utxo = acc.utxos.get(&new_utxo_hash).unwrap().clone();
|
||||
new_utxo.log();
|
||||
|
||||
info!(
|
||||
|
||||
Reference in New Issue
Block a user