Simplify some redundant code

Closes gh-24586

Co-authored-by: Sam Brannen <sbrannen@pivotal.io>
This commit is contained in:
ZhangT
2020-02-26 19:29:09 +08:00
committed by GitHub
parent 0ad942f337
commit c5fb7b9fb7
9 changed files with 9 additions and 19 deletions

View File

@@ -205,8 +205,7 @@ public class MethodMessageHandlerTests {
@Override
protected List<? extends HandlerMethodReturnValueHandler> initReturnValueHandlers() {
List<HandlerMethodReturnValueHandler> handlers = new ArrayList<>();
handlers.addAll(getCustomReturnValueHandlers());
List<HandlerMethodReturnValueHandler> handlers = new ArrayList<>(getCustomReturnValueHandlers());
return handlers;
}