Class: Rack::Request
- Inherits:
-
Object
- Object
- Rack::Request
- Defined in:
- lib/yodel/middleware/request.rb
Instance Method Summary collapse
-
#scheme_and_host ⇒ Object
almost verbatim copy of the ‘url’ method; just we don’t append the full_path to the constructed url.
Instance Method Details
#scheme_and_host ⇒ Object
almost verbatim copy of the ‘url’ method; just we don’t append the full_path to the constructed url
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/yodel/middleware/request.rb', line 5 def scheme_and_host url = scheme + "://" url << host if scheme == "https" && port != 443 || scheme == "http" && port != 80 url << ":#{port}" end url end |