lib/oehclient/interaction/interaction.rb in oeh-client-0.1.1 vs lib/oehclient/interaction/interaction.rb in oeh-client-0.1.2
- old
+ new
@@ -113,11 +113,11 @@
def send(parameters={})
# raise the MissingParameterException when one (or more) of the miminal parameters are missing
raise OEHClient::Exception::MissingParameterException.new(missing_minimal_parameters) unless (minimal_parameters?)
# call the appropriate method based on the existance of the timestamp value
- ((!@timestamp.nil? && @timestamp > 0) ? send_offline(@space.token) : send_realtime(@space.token, parameters))
+ ((!@timestamp.nil?) ? send_offline(@space.token) : send_realtime(@space.token, parameters))
# return the current instance interacton
self
end
@@ -185,10 +185,10 @@
end
# send_offline posts a historic interaction, using a specified timestamp
def send_offline(token)
- response = OHEClient::Helper::Response.handle(OEHClient.put(token,
+ response = OEHClient::Helper::Response.handle(OEHClient.put(token,
OEHClient::Helper::Request.format_url(offline_url, {:sk => @space.site_key}),
nil,
request_data))
map_response(response)
\ No newline at end of file