Skip to content

Commit 58309f2

Browse files
committed
fix: Modify the exception type to NumberFormatException.
1 parent 5012843 commit 58309f2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spring-tx/src/main/java/org/springframework/transaction/interceptor/DefaultTransactionAttribute.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ public void resolveAttributeStrings(@Nullable StringValueResolver resolver) {
204204
try {
205205
setTimeout(Integer.parseInt(timeoutString));
206206
}
207-
catch (RuntimeException ex) {
207+
catch (NumberFormatException ex) {
208208
throw new IllegalArgumentException(
209209
"Invalid timeoutString value \"" + timeoutString + "\" - cannot parse into int");
210210
}

0 commit comments

Comments
 (0)