Skip to content

Commit

Permalink
db: check for change using address strings only
Browse files Browse the repository at this point in the history
Comparing the address itself includes the network, but an
unchecked signet address will have its network set as testnet
by `assume_checked` and so change addresses will not be
matched.
  • Loading branch information
jp1ac4 committed Nov 15, 2023
1 parent 44f5a85 commit cfd1dd0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/database/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ impl DatabaseConnection for SqliteConn {
self.db_address(address).map(|db_addr| {
(
db_addr.derivation_index,
address == &db_addr.change_address.assume_checked(),
address.to_string() == db_addr.change_address.assume_checked().to_string(),
)
})
}
Expand Down

0 comments on commit cfd1dd0

Please sign in to comment.