#1059 - Cleanup the core codebase.
Clean up code containing various patterns: * Remove redundant `final`, `public`, and `static` declarations in interfaces and enums. * Replace redundant `? extends Object` generic parameters with `?`. * Convert collections to arrays using empty array instead of pre-sized one (modern JVM recommendation). * Initialize collections using constructor call over `addAll`. * Favor `addAll` over iterating and adding one-by-one. * Take advantage of `Map.forEach` that was introduced with Java 8.
This commit is contained in:
@@ -126,7 +126,7 @@ public class Traverson {
|
||||
return DEFAULTS.getHttpMessageConverters(Arrays.asList(mediaTypes));
|
||||
}
|
||||
|
||||
private static final RestOperations createDefaultTemplate(List<MediaType> mediaTypes) {
|
||||
private static RestOperations createDefaultTemplate(List<MediaType> mediaTypes) {
|
||||
|
||||
RestTemplate template = new RestTemplate();
|
||||
template.setMessageConverters(DEFAULTS.getHttpMessageConverters(mediaTypes));
|
||||
|
||||
Reference in New Issue
Block a user