Class: WEBrick::HTTPServer
- Inherits:
-
Object
- Object
- WEBrick::HTTPServer
show all
- Defined in:
- lib/ritm/helpers/patches.rb
Overview
Support other methods in HTTPServer
Instance Method Summary
collapse
Instance Method Details
#do_DELETE(req, res) ⇒ Object
35
36
37
38
39
|
# File 'lib/ritm/helpers/patches.rb', line 35
def do_DELETE(req, res)
perform_proxy_request(req, res) do |http, path, |
http.delete(path, )
end
end
|
#do_OPTIONS(_req, res) ⇒ Object
TODO: make sure options gets proxied too (so trace)
54
55
56
|
# File 'lib/ritm/helpers/patches.rb', line 54
def do_OPTIONS(_req, res)
res['allow'] = 'GET,HEAD,POST,PUT,PATCH,DELETE,OPTIONS,CONNECT'
end
|
#do_PATCH(req, res) ⇒ Object
47
48
49
50
51
|
# File 'lib/ritm/helpers/patches.rb', line 47
def do_PATCH(req, res)
perform_proxy_request(req, res) do |http, path, |
http.patch(path, req.body || '', )
end
end
|
#do_PUT(req, res) ⇒ Object
41
42
43
44
45
|
# File 'lib/ritm/helpers/patches.rb', line 41
def do_PUT(req, res)
perform_proxy_request(req, res) do |http, path, |
http.put(path, req.body || '', )
end
end
|