Skip to content

Commit

Permalink
Simplify error chain iteration
Browse files Browse the repository at this point in the history
  • Loading branch information
slowli committed Jun 26, 2024
1 parent db6485a commit 10640ca
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions core/lib/object_store/src/gcs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,7 @@ fn get_source<'a, T: StdError + 'static>(mut err: &'a (dyn StdError + 'static))
if let Some(err) = err.downcast_ref::<T>() {
return Some(err);
}
err = match err.source() {
Some(source) => source,
None => return None,
};
err = err.source()?;
}
}

Expand Down

0 comments on commit 10640ca

Please sign in to comment.