Class: Shaf::Authenticator::Request

Inherits:
Rack::Auth::AbstractRequest
  • Object
show all
Defined in:
lib/shaf/authenticator/request.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#envObject (readonly)

Returns the value of attribute env.



6
7
8
# File 'lib/shaf/authenticator/request.rb', line 6

def env
  @env
end

Instance Method Details

#authorizationObject



12
13
14
# File 'lib/shaf/authenticator/request.rb', line 12

def authorization
  env[authorization_key]
end

#valid?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'lib/shaf/authenticator/request.rb', line 8

def valid?
  !String(authorization).strip.empty?
end