Skip to content

Commit ef3e3c4

Browse files
committed
#711 - Polishing.
1 parent 8f15301 commit ef3e3c4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/main/java/org/springframework/hateoas/core/EncodingUtils.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ public static String encodePath(Object source) {
4646
try {
4747
return UriUtils.encodePath(source.toString(), ENCODING);
4848
} catch (Throwable e) {
49-
throw new RuntimeException(e);
49+
throw new IllegalStateException(e);
5050
}
5151
}
5252

@@ -63,7 +63,7 @@ public static String encodeParameter(Object source) {
6363
try {
6464
return UriUtils.encodeQueryParam(source.toString(), ENCODING);
6565
} catch (Throwable e) {
66-
throw new RuntimeException(e);
66+
throw new IllegalStateException(e);
6767
}
6868
}
6969

@@ -80,7 +80,7 @@ public static String encodeFragment(Object source) {
8080
try {
8181
return UriUtils.encodeFragment(source.toString(), ENCODING);
8282
} catch (Throwable e) {
83-
throw new RuntimeException(e);
83+
throw new IllegalStateException(e);
8484
}
8585
}
8686
}

0 commit comments

Comments
 (0)