Class: VersionCake::HttpHeaderStrategy
- Inherits:
-
ExtractionStrategy
- Object
- ExtractionStrategy
- VersionCake::HttpHeaderStrategy
- Defined in:
- lib/versioncake/strategies/http_header_strategy.rb
Instance Method Summary collapse
Methods inherited from ExtractionStrategy
#extract, list, lookup, #version_blank?, #version_key
Instance Method Details
#execute(request) ⇒ Object
4 5 6 7 8 |
# File 'lib/versioncake/strategies/http_header_strategy.rb', line 4 def execute(request) if request.env.key? "HTTP_#{version_key.upcase}" request.env["HTTP_#{version_key.upcase}"] end end |