From 9518457659e772f54c2d12f35b89a8c1722a9343 Mon Sep 17 00:00:00 2001 From: gmungoc Date: Fri, 8 Mar 2019 14:37:26 +0000 Subject: [PATCH] JAL-3193 defensive trim of URL read from properties file --- src/jalview/ext/ensembl/EnsemblSequenceFetcher.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/jalview/ext/ensembl/EnsemblSequenceFetcher.java b/src/jalview/ext/ensembl/EnsemblSequenceFetcher.java index 4da0e3c..8296985 100644 --- a/src/jalview/ext/ensembl/EnsemblSequenceFetcher.java +++ b/src/jalview/ext/ensembl/EnsemblSequenceFetcher.java @@ -92,9 +92,9 @@ abstract class EnsemblSequenceFetcher extends DbSourceProxyImpl * this allows an easy change from http to https in future if needed */ ensemblDomain = Cache.getDefault(ENSEMBL_BASEURL, - DEFAULT_ENSEMBL_BASEURL); + DEFAULT_ENSEMBL_BASEURL).trim(); ensemblGenomesDomain = Cache.getDefault(ENSEMBL_GENOMES_BASEURL, - DEFAULT_ENSEMBL_GENOMES_BASEURL); + DEFAULT_ENSEMBL_GENOMES_BASEURL).trim(); domain = ensemblDomain; } @@ -169,6 +169,6 @@ abstract class EnsemblSequenceFetcher extends DbSourceProxyImpl protected void setDomain(String d) { - domain = d; + domain = d == null ? null : d.trim(); } } -- 1.7.10.2