Commit afda71e4 authored by dreis2211's avatar dreis2211 Committed by Stephane Nicoll

Polish some joining collectors

Closes gh-14221
parent 3997b3ae
...@@ -61,8 +61,8 @@ class DiscoveredWebOperation extends AbstractDiscoveredOperation implements WebO ...@@ -61,8 +61,8 @@ class DiscoveredWebOperation extends AbstractDiscoveredOperation implements WebO
} }
private String getId(String endpointId, Method method) { private String getId(String endpointId, Method method) {
return endpointId + Stream.of(method.getParameters()).filter(this::hasSelector) return Stream.of(method.getParameters()).filter(this::hasSelector)
.map(this::dashName).collect(Collectors.joining()); .map(this::dashName).collect(Collectors.joining("", endpointId, ""));
} }
private boolean hasSelector(Parameter parameter) { private boolean hasSelector(Parameter parameter) {
......
...@@ -62,8 +62,8 @@ class RequestPredicateFactory { ...@@ -62,8 +62,8 @@ class RequestPredicateFactory {
} }
private String getPath(String rootPath, Method method) { private String getPath(String rootPath, Method method) {
return rootPath + Stream.of(method.getParameters()).filter(this::hasSelector) return Stream.of(method.getParameters()).filter(this::hasSelector)
.map(this::slashName).collect(Collectors.joining()); .map(this::slashName).collect(Collectors.joining("", rootPath, ""));
} }
private boolean hasSelector(Parameter parameter) { private boolean hasSelector(Parameter parameter) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment