Skip to content
Snippets Groups Projects
Commit 57b2c604 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

Merge branch '496_taxonomy_connector' into 'devel_12.0.x'

taxonomy changed html response

See merge request !388
parents 608161ae a82625d3
No related branches found
No related tags found
3 merge requests!39112.0.4 into master,!39012.0.4 merged into 12.1.x,!388taxonomy changed html response
Pipeline #6349 passed
......@@ -108,7 +108,7 @@ public class TaxonomyBackend extends CachableInterface implements IExternalServi
queryTerm = URLEncoder.encode(queryTerm, "UTF-8");
String url = "https://www.ncbi.nlm.nih.gov/Taxonomy/Browser/wwwtax.cgi?lvl=0&name=" + queryTerm;
String page = getWebPageContent(url);
Pattern idPattern = Pattern.compile("<em>Taxonomy ID: </em>([0-9]+)");
Pattern idPattern = Pattern.compile("Taxonomy ID: ([0-9]+)");
Matcher matcher = idPattern.matcher(page);
if (!matcher.find()) {
logger.warn("Unknown organism: " + term);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment