From 0eae966439dda0d2cd5ded8cbc01b3af428a3b4d Mon Sep 17 00:00:00 2001 From: bnasslahsen Date: Tue, 5 May 2020 22:16:16 +0200 Subject: [PATCH] code review --- .../main/java/org/springdoc/webmvc/api/OpenApiResource.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/springdoc-openapi-webmvc-core/src/main/java/org/springdoc/webmvc/api/OpenApiResource.java b/springdoc-openapi-webmvc-core/src/main/java/org/springdoc/webmvc/api/OpenApiResource.java index 0a92124c3..408148a0d 100644 --- a/springdoc-openapi-webmvc-core/src/main/java/org/springdoc/webmvc/api/OpenApiResource.java +++ b/springdoc-openapi-webmvc-core/src/main/java/org/springdoc/webmvc/api/OpenApiResource.java @@ -168,7 +168,8 @@ && isPathToMatch(operationPath)) { } } } - routerFunctionProvider.flatMap(RouterFunctionProvider::getWebMvcRouterFunctionPaths).ifPresent(routerBeans -> routerBeans.forEach(this::getRouterFunctionPaths)); + routerFunctionProvider.ifPresent(routerFunctions -> routerFunctions.getWebMvcRouterFunctionPaths() + .ifPresent(routerBeans -> routerBeans.forEach(this::getRouterFunctionPaths))); }