Public Instance methods
build_request(*)
[show source]
# File lib/httpx/plugins/server_sent_events.rb 49 def build_request(*) 50 super.tap do |request| 51 if request.options.event_stream 52 request.headers["accept"] = "text/event-stream" 53 request.headers["cache-control"] = "no-cache" 54 end 55 end 56 end
request(*args, **options)
[show source]
# File lib/httpx/plugins/server_sent_events.rb 43 def request(*args, **options) 44 options[:stream] = true if options[:event_stream] 45 46 super 47 end