diff options
Diffstat (limited to 'lib/algorithm.rb')
-rw-r--r-- | lib/algorithm.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/algorithm.rb b/lib/algorithm.rb index 33731af..7007e3a 100644 --- a/lib/algorithm.rb +++ b/lib/algorithm.rb @@ -15,7 +15,9 @@ module OpenTox end def self.weighted_tanimoto(dataset1,compound1,dataset2,compound2) - RestClient.get URI.encode(File.join(@@config[:services]["opentox-dataset"], 'algorithm/weighted_tanimoto/dataset',dataset1.name,'compound',compound1.inchi,'dataset',dataset2.name,'compound',compound2.inchi)) + # URI.escape does not work here + uri = File.join(@@config[:services]["opentox-dataset"], 'algorithm/weighted_tanimoto/dataset',CGI.escape(dataset1.name),'compound',CGI.escape(compound1.inchi),'dataset',CGI.escape(dataset2.name),'compound',CGI.escape(compound2.inchi)) + RestClient.get uri end end |