Fix bug, dont' send a cipher to ourselves when updating
This commit is contained in:
parent
4d04e50a65
commit
d7cd98ffe8
@ -1294,6 +1294,7 @@ pub fn create_update_transaction(
|
||||
let local_device = lock_local_device()?;
|
||||
|
||||
let sp_wallet = local_device.get_wallet();
|
||||
let local_address = sp_wallet.get_client().get_receiving_address();
|
||||
|
||||
let sender: Member = local_device
|
||||
.to_member()
|
||||
@ -1342,6 +1343,10 @@ pub fn create_update_transaction(
|
||||
|
||||
let addresses = member.get_addresses();
|
||||
for sp_address in addresses.into_iter() {
|
||||
// We skip our own device address, no point sending ourself a cipher
|
||||
if sp_address == local_address {
|
||||
continue;
|
||||
}
|
||||
let shared_point = sp_utils::sending::calculate_ecdh_shared_secret(
|
||||
&<SilentPaymentAddress>::try_from(sp_address.as_str())?.get_scan_key(),
|
||||
&partial_secret,
|
||||
|
Loading…
x
Reference in New Issue
Block a user