Skip to content

Conversation

@gracekarina
Copy link
Contributor

@gracekarina gracekarina commented Dec 16, 2017

fixing bug when parser trying to solve remote ref in additional properties schema issue #342

@gracekarina gracekarina requested a review from webron December 16, 2017 04:54
@gracekarina gracekarina changed the title Schema with Additional properties was not being solving remote refs Schema with Additional properties was not solving remote refs Dec 16, 2017
@gracekarina gracekarina changed the title Schema with Additional properties was not solving remote refs Schema with Additional properties was not solving remote refs #342 Dec 16, 2017
processRefProperty(additionalProperty, file);
} else if (additionalProperty instanceof ArraySchema) {
ArraySchema arrayProp = (ArraySchema) additionalProperty;
if (arrayProp.getItems().get$ref() != null) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

how are we sure that "getItems()" won't return null?

if (mapProp.getAdditionalProperties().get$ref() != null) {
processRefProperty(mapProp.getAdditionalProperties(), file);
} else if (mapProp.getAdditionalProperties() instanceof ArraySchema &&
((ArraySchema) mapProp.getAdditionalProperties()).getItems().get$ref() != null) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same question here.

@HugoMario HugoMario merged commit 5bd6721 into 2.0 Dec 21, 2017
@HugoMario HugoMario deleted the check-additional-properties-solving branch December 21, 2017 05:33
@gracekarina gracekarina changed the title Schema with Additional properties was not solving remote refs #342 Schema with Additional properties was not solving remote refs #342 #423 Dec 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants