Skip to content

Commit

Permalink
Use streams in the HTTP client example
Browse files Browse the repository at this point in the history
  • Loading branch information
iconara committed Nov 9, 2014
1 parent c9c04e5 commit da43818
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/http_client/lib/ione/http_client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def get(url, headers={})
class HttpProtocolHandler
def initialize(connection)
@connection = connection
@connection.on_data(&method(:process_data))
@connection.to_stream.subscribe(method(:process_data))
@http_parser = Http::Parser.new(self)
@promises = []
end
Expand Down

0 comments on commit da43818

Please sign in to comment.