Skip to content

Commit

Permalink
Undo changes (#1570)
Browse files Browse the repository at this point in the history
* Undo changes

* Add change files
  • Loading branch information
Thoralf-M authored Nov 15, 2022
1 parent 38efc26 commit 48db2d2
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 24 deletions.
5 changes: 5 additions & 0 deletions .changes/account-recovery.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"nodejs-binding": patch
---

Don't require address approval on ledger nano during account recovery.
5 changes: 5 additions & 0 deletions .changes/syncing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"nodejs-binding": patch
---

Sync outputs with expiration unlock condition, even when they can't be unlocked currently.
8 changes: 4 additions & 4 deletions src/account/operations/output_finder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ impl AccountHandle {
Some(AddressGenerationOptions {
internal: false,
metadata: GenerateAddressOptions {
ledger_nano_prompt: true,
ledger_nano_prompt: false,
},
}),
)
Expand All @@ -78,7 +78,7 @@ impl AccountHandle {
Some(AddressGenerationOptions {
internal: true,
metadata: GenerateAddressOptions {
ledger_nano_prompt: true,
ledger_nano_prompt: false,
},
}),
)
Expand Down Expand Up @@ -113,7 +113,7 @@ impl AccountHandle {
Some(AddressGenerationOptions {
internal: false,
metadata: GenerateAddressOptions {
ledger_nano_prompt: true,
ledger_nano_prompt: false,
},
}),
)
Expand All @@ -124,7 +124,7 @@ impl AccountHandle {
Some(AddressGenerationOptions {
internal: true,
metadata: GenerateAddressOptions {
ledger_nano_prompt: true,
ledger_nano_prompt: false,
},
}),
)
Expand Down
11 changes: 1 addition & 10 deletions src/account/operations/syncing/addresses/output_ids/basic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,16 +65,7 @@ impl AccountHandle {
let client = client.clone();
tokio::spawn(async move {
client
.basic_output_ids(vec![
QueryParameter::ExpirationReturnAddress(bech32_address),
// Ignore outputs that aren't expired yet
QueryParameter::ExpiresBefore(
std::time::SystemTime::now()
.duration_since(std::time::UNIX_EPOCH)
.expect("time went backwards")
.as_secs() as u32,
),
])
.basic_output_ids(vec![QueryParameter::ExpirationReturnAddress(bech32_address)])
.await
.map_err(From::from)
})
Expand Down
11 changes: 1 addition & 10 deletions src/account/operations/syncing/addresses/output_ids/nft.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,7 @@ impl AccountHandle {
tokio::spawn(async move {
// Get outputs where the address is in the expiration unlock condition
client
.nft_output_ids(vec![
QueryParameter::ExpirationReturnAddress(bech32_address_),
// Ignore outputs that aren't expired yet
QueryParameter::ExpiresBefore(
std::time::SystemTime::now()
.duration_since(std::time::UNIX_EPOCH)
.expect("time went backwards")
.as_secs() as u32,
),
])
.nft_output_ids(vec![QueryParameter::ExpirationReturnAddress(bech32_address_)])
.await
.map_err(From::from)
})
Expand Down

0 comments on commit 48db2d2

Please sign in to comment.