Class: Kadmin::Auth::User
- Inherits:
-
Object
- Object
- Kadmin::Auth::User
- Defined in:
- lib/kadmin/auth/user.rb
Instance Attribute Summary collapse
-
#accept ⇒ Object
Returns the value of attribute accept.
-
#email ⇒ Object
Returns the value of attribute email.
-
#organization ⇒ Object
Returns the value of attribute organization.
Instance Method Summary collapse
- #admin? ⇒ Boolean
- #authorized?(_request) ⇒ Boolean
-
#initialize(email, options = {}) ⇒ User
constructor
A new instance of User.
Constructor Details
#initialize(email, options = {}) ⇒ User
Returns a new instance of User.
6 7 8 9 10 11 |
# File 'lib/kadmin/auth/user.rb', line 6 def initialize(email, = {}) @email = email @admin = [:admin] @organization = [:organization] @accept = [:accept] end |
Instance Attribute Details
#accept ⇒ Object
Returns the value of attribute accept.
4 5 6 |
# File 'lib/kadmin/auth/user.rb', line 4 def accept @accept end |
#email ⇒ Object
Returns the value of attribute email.
4 5 6 |
# File 'lib/kadmin/auth/user.rb', line 4 def email @email end |
#organization ⇒ Object
Returns the value of attribute organization.
4 5 6 |
# File 'lib/kadmin/auth/user.rb', line 4 def organization @organization end |
Instance Method Details
#admin? ⇒ Boolean
21 22 23 |
# File 'lib/kadmin/auth/user.rb', line 21 def admin? return @admin end |
#authorized?(_request) ⇒ Boolean
17 18 19 |
# File 'lib/kadmin/auth/user.rb', line 17 def (_request) return true end |