Class: Junebug::Models::User

Inherits:
Base
  • Object
show all
Defined in:
lib/junebug/models.rb

Constant Summary collapse

ROLE_USER =
0
ROLE_ADMIN =
10

Instance Method Summary collapse

Instance Method Details

#password=(text) ⇒ Object



21
22
23
# File 'lib/junebug/models.rb', line 21

def password=(text)
  write_attribute(:password, (text ? text.strip : text) )
end

#username=(text) ⇒ Object



17
18
19
# File 'lib/junebug/models.rb', line 17

def username=(text)
  write_attribute(:username, (text ? text.strip.downcase : text) )
end