maybe the instantiate method will help
This commit is contained in:
parent
0f6ec71dcd
commit
0a3277d306
1 changed files with 6 additions and 1 deletions
|
|
@ -297,7 +297,12 @@ class User
|
|||
end
|
||||
|
||||
###Helpers############
|
||||
|
||||
def self.instantiate( opts = {} )
|
||||
opts[:person][:email] = opts[:email]
|
||||
opts[:person][:serialized_key] = generate_key
|
||||
User.create( opts)
|
||||
end
|
||||
|
||||
def terse_url
|
||||
terse= self.url.gsub(/https?:\/\//, '')
|
||||
terse.gsub!(/www\./, '')
|
||||
|
|
|
|||
Loading…
Reference in a new issue