diff options
author | mguetlein <martin.guetlein@gmail.com> | 2010-05-17 12:00:32 +0200 |
---|---|---|
committer | mguetlein <martin.guetlein@gmail.com> | 2010-05-17 12:00:32 +0200 |
commit | 6b8e7eed61c4f8e2585062c92a57a04b02b0d00e (patch) | |
tree | ffa69e09c2d45c09238966a42487063365ecb1d5 | |
parent | 69c31b3d16530c369506c6d03e138c6fdccbf155 (diff) |
get dataset as yaml
-rw-r--r-- | lib/dataset.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/dataset.rb b/lib/dataset.rb index aea12b5..e506305 100644 --- a/lib/dataset.rb +++ b/lib/dataset.rb @@ -15,13 +15,12 @@ module OpenTox def self.find(uri, accept_header=nil) unless accept_header - if uri.match(@@config[:services]["opentox-dataset"]) || uri=~ /188.40.32.88/ + if uri.match(@@config[:services]["opentox-dataset"]) || uri=~ /188.40.32.88/ || uri =~ /in-silico.ch/ accept_header = 'text/x-yaml' else accept_header = "application/rdf+xml" end end - case accept_header when "text/x-yaml" d = YAML.load RestClientWrapper.get(uri.to_s.strip, :accept => 'text/x-yaml').to_s |