Polish: lamdbas containing only one statement should not nest this statement in a block
This commit is contained in:
committed by
Juergen Hoeller
parent
99662bc702
commit
7826567df6
@@ -91,10 +91,8 @@ public abstract class ExchangeFilterFunctions {
|
||||
clientRequest -> credentialsFunction.apply(clientRequest).map(
|
||||
credentials -> {
|
||||
ClientRequest authorizedRequest = ClientRequest.from(clientRequest)
|
||||
.headers(headers -> {
|
||||
headers.set(HttpHeaders.AUTHORIZATION,
|
||||
authorization(credentials));
|
||||
})
|
||||
.headers(headers -> headers.set(HttpHeaders.AUTHORIZATION,
|
||||
authorization(credentials)))
|
||||
.build();
|
||||
return Mono.just(authorizedRequest);
|
||||
})
|
||||
|
||||
@@ -114,9 +114,7 @@ public class RouterFunctionMapping extends AbstractHandlerMapping implements Ini
|
||||
|
||||
List<RouterFunction<?>> routerFunctions = routerFunctions();
|
||||
if (!CollectionUtils.isEmpty(routerFunctions) && logger.isInfoEnabled()) {
|
||||
routerFunctions.forEach(routerFunction -> {
|
||||
logger.info("Mapped " + routerFunction);
|
||||
});
|
||||
routerFunctions.forEach(routerFunction -> logger.info("Mapped " + routerFunction));
|
||||
}
|
||||
this.routerFunction = routerFunctions.stream()
|
||||
.reduce(RouterFunction::andOther)
|
||||
|
||||
Reference in New Issue
Block a user