Skip to content

Commit

Permalink
Typo 'thrown'. Catch and throw unknown exception as IOException.
Browse files Browse the repository at this point in the history
Signed-off-by: Finn Carroll <[email protected]>
  • Loading branch information
finnegancarroll committed Nov 5, 2024
1 parent 090c36d commit 7978e4e
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,9 @@ public IndexInput fetchBlob(BlobFetchRequest blobFetchRequest) throws IOExceptio
} catch (PrivilegedActionException e) {
final Exception cause = e.getException();
if (cause instanceof IOException) {
thrown (IOException) cause;
throw (IOException) cause;
} else if (cause instanceof RuntimeException) {
thrown (RuntimeException) cause;
} else if (cause instanceof Error) {
thrown (Error) cause;
throw (RuntimeException) cause;

Check warning on line 102 in server/src/main/java/org/opensearch/index/store/remote/utils/TransferManager.java

View check run for this annotation

Codecov / codecov/patch

server/src/main/java/org/opensearch/index/store/remote/utils/TransferManager.java#L102

Added line #L102 was not covered by tests
} else {
throw new IOException(cause);

Check warning on line 104 in server/src/main/java/org/opensearch/index/store/remote/utils/TransferManager.java

View check run for this annotation

Codecov / codecov/patch

server/src/main/java/org/opensearch/index/store/remote/utils/TransferManager.java#L104

Added line #L104 was not covered by tests
}
Expand Down

0 comments on commit 7978e4e

Please sign in to comment.