Skip to content

Commit

Permalink
fix: .expect_result() returns Result<Result<..>, ..>, so try! to re…
Browse files Browse the repository at this point in the history
…move that outer error before acting on a blanket `Ok(_)` / `Err(_)` match
  • Loading branch information
jcnelson committed Feb 10, 2024
1 parent d3f20d2 commit 7f7707c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clarity/src/vm/contexts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1359,7 +1359,7 @@ impl<'a, 'b, 'hooks> Environment<'a, 'b, 'hooks> {
self.global_context.begin();
let result = stx_transfer_consolidated(self, from, to, amount, memo);
match result {
Ok(value) => match value.clone().expect_result() {
Ok(value) => match value.clone().expect_result()? {
Ok(_) => {
self.global_context.commit()?;
Ok(value)
Expand Down

0 comments on commit 7f7707c

Please sign in to comment.