module Roda::RodaPlugins::Head::RequestMethods
Public Instance Methods
Source
# File lib/roda/plugins/head.rb, line 76 def is_get? super || head? end
Consider HEAD requests as GET requests.
Calls superclass method
Private Instance Methods
Source
# File lib/roda/plugins/head.rb, line 84 def match_method(method) super || (!method.is_a?(Array) && head? && method.to_s.upcase == 'GET') end
If the current request is a HEAD request, match if one of the given methods is a GET request.
Calls superclass method
Source
# File lib/roda/plugins/head.rb, line 90 def method_not_allowed(verbs) verbs = verbs.sub('GET', 'HEAD, GET') super end
Work with the not_allowed plugin so that if GET is one of the Allow header options, then HEAD is as well.
Calls superclass method