summaryrefslogtreecommitdiff
path: root/lib/rest_client_wrapper.rb
diff options
context:
space:
mode:
authormguetlein <martin.guetlein@gmail.com>2011-02-10 09:35:20 +0100
committermguetlein <martin.guetlein@gmail.com>2011-02-10 09:35:20 +0100
commit0011577686ede0b2670b7ad791185fef5871fee1 (patch)
treedd7be4453b28090ebfa318c17c3c6f7ca5ef1507 /lib/rest_client_wrapper.rb
parente8b8f16cffc0401f4f51c7b5c68198dbe2b89ad2 (diff)
parent65f6d64e57c81ae7b6dd72209fbeffee2d60da71 (diff)
merged with michas version
Diffstat (limited to 'lib/rest_client_wrapper.rb')
-rw-r--r--lib/rest_client_wrapper.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/rest_client_wrapper.rb b/lib/rest_client_wrapper.rb
index 626f94f..7a6ed2a 100644
--- a/lib/rest_client_wrapper.rb
+++ b/lib/rest_client_wrapper.rb
@@ -64,6 +64,9 @@ module OpenTox
## PENDING partner services accept subjectid only in header
headers[:subjectid] = payload.delete(:subjectid) if payload and payload.is_a?(Hash) and payload.has_key?(:subjectid)
+ # PENDING needed for NUTA, until we finally agree on how to send subjectid
+ headers[:subjectid] = payload.delete(:subjectid) if uri=~/ntua/ and payload and payload.is_a?(Hash) and payload.has_key?(:subjectid)
+
begin
#LOGGER.debug "RestCall: "+rest_call.to_s+" "+uri.to_s+" "+headers.inspect+" "+payload.inspect
resource = RestClient::Resource.new(uri,{:timeout => 60})