meteor - How can I set the password of a user created in a fixture -


i create user in fixture , able sign in user. reason, need somehow set password of user (if try sign in without password, 'user has no password set' validation error).

so far have:

var joeid = meteor.users.insert({     username: 'joe' }) 

using http://docs.meteor.com/#accounts_createuser can this:

accounts.createuser({   'username'  : 'john doe',   'email'     : 'john@doe.com',   'password'  : 'abc123' //encrypted automatically  }, function(err){   if(typeof err === 'undefined'){     //account created might want send email user using account.sendenrollmentemail()   } }); 

which login user on successful creation.


Comments

Popular posts from this blog

user interface - Python attempting to create a simple gui, getting "AttributeError: 'MainMenu' object has no attribute 'intro_screen'" -

jquery - Common JavaScript snippet to share files on Google Drive, Dropbox, Box.net or SkyDrive -

Android Gson.fromJson error -