Skip to content

Commit

Permalink
Fix for issue reported by Hanna
Browse files Browse the repository at this point in the history
  • Loading branch information
djcomlab committed Dec 5, 2017
1 parent fcdd648 commit c150336
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,12 @@ public Map<String, Ontology> getAllOntologies() {

Map<String, Ontology> result = new HashMap<String, Ontology>();
String content = queryOntologyEndpoint();

if (content.contains("Internal server error")) {
System.err.println("The BioPortal REST service reports Internal server error");
return result;
}

JSONArray obj = (JSONArray) JSONValue.parse(content);

for (Object resultItem : obj) {
Expand Down

0 comments on commit c150336

Please sign in to comment.