Class: Stitches::ApiKey::UnauthorizedResponse

Inherits:
Rack::Response
  • Object
show all
Defined in:
lib/stitches/api_key.rb

Instance Method Summary collapse

Constructor Details

#initialize(reason, realm, custom_http_auth_scheme) ⇒ UnauthorizedResponse

Returns a new instance of UnauthorizedResponse.



61
62
63
# File 'lib/stitches/api_key.rb', line 61

def initialize(reason,realm,custom_http_auth_scheme)
  super("Unauthorized - #{reason}", 401, { "WWW-Authenticate" => "#{custom_http_auth_scheme} realm=#{realm}" })
end