Skip to content

Commit

Permalink
fixes #2595
Browse files Browse the repository at this point in the history
  • Loading branch information
nathandunn committed Mar 21, 2021
1 parent 7b148ed commit a54917b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,13 @@ public static GeneProduct convertFromJson(JSONObject object) {
String withOrFromString = object.get("withOrFrom").isString().stringValue();
JSONArray withOrFromArray = JSONParser.parseLenient(withOrFromString).isArray();
for (int i = 0; i < withOrFromArray.size(); i++) {
WithOrFrom withOrFrom = new WithOrFrom(withOrFromArray.get(i).isString().stringValue());
WithOrFrom withOrFrom ;
if(withOrFromArray.get(i).isString()!=null){
withOrFrom = new WithOrFrom(withOrFromArray.get(i).isString().stringValue());
}
else{
withOrFrom = new WithOrFrom("Value is an error, please edit or delete: "+withOrFromArray.get(i));
}
withOrFromList.add(withOrFrom);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,13 @@ public static GoAnnotation convertFromJson(JSONObject object) {
String withOrFromString = object.get("withOrFrom").isString().stringValue();
JSONArray withOrFromArray = JSONParser.parseLenient(withOrFromString).isArray();
for (int i = 0; i < withOrFromArray.size(); i++) {
WithOrFrom withOrFrom = new WithOrFrom(withOrFromArray.get(i).isString().stringValue());
WithOrFrom withOrFrom ;
if(withOrFromArray.get(i).isString()!=null){
withOrFrom = new WithOrFrom(withOrFromArray.get(i).isString().stringValue());
}
else{
withOrFrom = new WithOrFrom("Value is an error, please edit or delete: "+withOrFromArray.get(i));
}
withOrFromList.add(withOrFrom);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,13 @@ public static Provenance convertFromJson(JSONObject object) {
String withOrFromString = object.get("withOrFrom").isString().stringValue();
JSONArray withOrFromArray = JSONParser.parseLenient(withOrFromString).isArray();
for (int i = 0; i < withOrFromArray.size(); i++) {
WithOrFrom withOrFrom = new WithOrFrom(withOrFromArray.get(i).isString().stringValue());
WithOrFrom withOrFrom ;
if(withOrFromArray.get(i).isString()!=null){
withOrFrom = new WithOrFrom(withOrFromArray.get(i).isString().stringValue());
}
else{
withOrFrom = new WithOrFrom("Value is an error, please edit or delete: "+withOrFromArray.get(i));
}
withOrFromList.add(withOrFrom);
}
}
Expand Down

0 comments on commit a54917b

Please sign in to comment.