Skip to content

Commit a79d2e9

Browse files
committed
break in loop
1 parent 6c8d9ea commit a79d2e9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/client/retry.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -740,8 +740,9 @@ mod tests {
740740
while let Some(source) = err.source() {
741741
err = source;
742742
if let Some(http_err) = err.downcast_ref::<HttpError>() {
743-
found = true;
744743
assert_eq!(http_err.kind(), HttpErrorKind::Request);
744+
found = true;
745+
break;
745746
}
746747
}
747748
assert!(found, "HttpError not found in source chain");

0 commit comments

Comments
 (0)