Skip to content

Commit ce41a27

Browse files
author
bnasslahsen
committed
Improve support of Webflux with Functional Endpoints
1 parent 8e0b773 commit ce41a27

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

springdoc-openapi-common/src/main/java/org/springdoc/core/MethodParameterPojoExtractor.java

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,7 @@ class MethodParameterPojoExtractor {
4949

5050
private MethodParameterPojoExtractor() { }
5151

52-
private static final Nullable NULLABLE_ANNOTATION = new Nullable() {
53-
public Class<? extends Annotation> annotationType() {
54-
return Nullable.class;
55-
}
56-
};
52+
private static final Nullable NULLABLE_ANNOTATION = getNullable();
5753

5854
private static final List<Predicate<Class<?>>> SIMPLE_TYPE_PREDICATES = new ArrayList<>();
5955

@@ -145,4 +141,12 @@ static void addSimpleTypes(Class<?>... classes) {
145141
static void removeSimpleTypes(Class<?>... classes) {
146142
SIMPLE_TYPES.removeAll(Arrays.asList(classes));
147143
}
144+
145+
private static Nullable getNullable() {
146+
return new Nullable() {
147+
public Class<? extends Annotation> annotationType() {
148+
return Nullable.class;
149+
}
150+
};
151+
}
148152
}

0 commit comments

Comments
 (0)