lib/rainbows/http_response.rb in rainbows-0.95.1 vs lib/rainbows/http_response.rb in rainbows-0.96.0
- old
+ new
@@ -2,23 +2,22 @@
# :enddoc:
# deprecated, use Rainbows::Response instead
# Cramp 0.11 relies on this, and is only activated by Cramp
if defined?(Cramp) && defined?(Rainbows::EventMachine::Client)
class Rainbows::HttpResponse
- class << self
- include Rainbows::Response
- alias write write_response
+ # dummy method for Cramp to alias_method_chain
+ def self.write(client, response, out)
end
end
module Rainbows::EventMachine::CrampSocket
- def write_header(_, response, out)
+ def em_write_response(response, alive = false)
if websocket?
write web_socket_upgrade_data
web_socket_handshake!
- out = nil # disable response headers
+ response[1] = nil # disable response headers
end
- super(self, response, out)
+ super
end
end
class Rainbows::EventMachine::Client
include Rainbows::EventMachine::CrampSocket