Browse Source

Polishing

pull/25349/head
Arjen Poutsma 4 years ago
parent
commit
20254f02d2
  1. 4
      spring-webflux/src/main/java/org/springframework/web/reactive/function/server/RouterFunctionBuilder.java
  2. 4
      spring-webmvc/src/main/java/org/springframework/web/servlet/function/RouterFunctionBuilder.java

4
spring-webflux/src/main/java/org/springframework/web/reactive/function/server/RouterFunctionBuilder.java

@ -266,11 +266,11 @@ class RouterFunctionBuilder implements RouterFunctions.Builder { @@ -266,11 +266,11 @@ class RouterFunctionBuilder implements RouterFunctions.Builder {
*/
private static class BuiltRouterFunction extends RouterFunctions.AbstractRouterFunction<ServerResponse> {
private List<RouterFunction<ServerResponse>> routerFunctions;
private final List<RouterFunction<ServerResponse>> routerFunctions;
public BuiltRouterFunction(List<RouterFunction<ServerResponse>> routerFunctions) {
Assert.notEmpty(routerFunctions, "RouterFunctions must not be empty");
this.routerFunctions = routerFunctions;
this.routerFunctions = new ArrayList<>(routerFunctions);
}
@Override

4
spring-webmvc/src/main/java/org/springframework/web/servlet/function/RouterFunctionBuilder.java

@ -261,11 +261,11 @@ class RouterFunctionBuilder implements RouterFunctions.Builder { @@ -261,11 +261,11 @@ class RouterFunctionBuilder implements RouterFunctions.Builder {
*/
private static class BuiltRouterFunction extends RouterFunctions.AbstractRouterFunction<ServerResponse> {
private List<RouterFunction<ServerResponse>> routerFunctions;
private final List<RouterFunction<ServerResponse>> routerFunctions;
public BuiltRouterFunction(List<RouterFunction<ServerResponse>> routerFunctions) {
Assert.notEmpty(routerFunctions, "RouterFunctions must not be empty");
this.routerFunctions = routerFunctions;
this.routerFunctions = new ArrayList<>(routerFunctions);
}
@Override

Loading…
Cancel
Save