Skip to content

Commit

Permalink
added custom sat value 0 to not affect indexer parts number
Browse files Browse the repository at this point in the history
  • Loading branch information
crypticmeta committed Sep 19, 2024
1 parent a1c768c commit 8fca3e1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index/updater/inscription_updater.rs
Original file line number Diff line number Diff line change
Expand Up @@ -875,7 +875,7 @@ fn write_to_file(&mut self, to_write: String, flush: bool) -> Result {
// .unwrap_or_else(|_| String::from("Invalid UTF-8"));
self.write_to_file(
format!(
"cmd~||~height:{}~||~insert~||~content~||~inscription_number:{}~||~inscription_id:{}~||~is_json:{}~||~content_type:{}~||~metaprotocol:{}~||~content:{:?}~||~parents:{}~||~timestamp:{}~||~location:{:?}~||~charms:{}~||~output_value:{}~||~address:{:?}~||~delegate:{:?}~||~sha:{:?}~||~rune:{:?}~||~metadata:{:?}",
"cmd~||~height:{}~||~insert~||~content~||~inscription_number:{}~||~inscription_id:{}~||~is_json:{}~||~content_type:{}~||~metaprotocol:{}~||~content:{:?}~||~parents:{}~||~sat:{:?}~||~timestamp:{}~||~location:{:?}~||~charms:{}~||~output_value:{}~||~address:{:?}~||~delegate:{:?}~||~sha:{:?}~||~rune:{:?}~||~metadata:{:?}",
self.height,
inscription_number,
flotsam.inscription_id,
Expand All @@ -887,7 +887,7 @@ fn write_to_file(&mut self, to_write: String, flush: bool) -> Result {
.iter()
.map(|p| p.to_string())
.collect::<Vec<_>>()
.join(","), timestamp,(!unbound).then_some(new_satpoint), charms, new_output_value.unwrap_or(&0), // Provide a default output value of 0 if none
.join(","),0, timestamp,(!unbound).then_some(new_satpoint), charms, new_output_value.unwrap_or(&0), // Provide a default output value of 0 if none
new_script_pubkey
.and_then(|script| Some(self.chain.address_from_script(script))) // Convert script to address
.map_or_else(
Expand Down

0 comments on commit 8fca3e1

Please sign in to comment.