mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
explicit call to UserCreator.createNewUser
This commit is contained in:
parent
3bc3153490
commit
f3e48e332b
2 changed files with 2 additions and 2 deletions
|
@ -36,7 +36,7 @@ module.exports = UserRegistrationHandler =
|
|||
_createNewUserIfRequired: (user, userDetails, callback)->
|
||||
if !user?
|
||||
userDetails.holdingAccount = false
|
||||
UserCreator.createNewUser userDetails, callback
|
||||
UserCreator.createNewUser {holdingAccount:false, email:userDetails.email, first_name:userDetails.first_name, last_name:userDetails.last_name}, callback
|
||||
else
|
||||
callback null, user
|
||||
|
||||
|
|
|
@ -106,7 +106,7 @@ describe "UserRegistrationHandler", ->
|
|||
|
||||
it "should create a new user", (done)->
|
||||
@handler.registerNewUser @passingRequest, (err)=>
|
||||
@UserCreator.createNewUser.calledWith({email:@passingRequest.email, holdingAccount:false, password:"123"}).should.equal true
|
||||
@UserCreator.createNewUser.calledWith({email:@passingRequest.email, holdingAccount:false, first_name:@passingRequest.first_name, last_name:@passingRequest.last_name}).should.equal true
|
||||
done()
|
||||
|
||||
it 'lower case email', (done)->
|
||||
|
|
Loading…
Reference in a new issue