Class: Stitches::ApiKey::UnauthorizedResponse
- Inherits:
-
Rack::Response
- Object
- Rack::Response
- Stitches::ApiKey::UnauthorizedResponse
- Defined in:
- lib/stitches/api_key.rb
Instance Method Summary collapse
-
#initialize(reason, realm, custom_http_auth_scheme) ⇒ UnauthorizedResponse
constructor
A new instance of UnauthorizedResponse.
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 |