Skip to content

Commit d509df2

Browse files
committed
refractored code
1 parent b909a97 commit d509df2

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

modules/swagger-parser-v3/src/main/java/io/swagger/v3/parser/util/OpenAPIDeserializer.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2196,10 +2196,13 @@ public Schema getSchema(ObjectNode node, String location, ParseResult result){
21962196
}
21972197

21982198
bool = getBoolean("deprecated", node, false, location, result);
2199-
schema.setDeprecated(false);
2199+
22002200
if(bool != null){
22012201
schema.setDeprecated(bool);
22022202
}
2203+
else {
2204+
schema.setDeprecated(false);
2205+
}
22032206

22042207
Map <String,Object> extensions = getExtensions(node);
22052208
if(extensions != null && extensions.size() > 0) {

0 commit comments

Comments
 (0)