ianmartorell / meteor-accounts-ui-bootstrap-3

accounts-ui package with Bootstrap 3 and localization support
150 stars 109 forks source link

Exception while invoking method 'createUser' #78

Closed raduchiriac closed 9 years ago

raduchiriac commented 9 years ago

I have a problem when trying to create an account using accounts-password. If I use the usual accounts-ui or accounts-facebook everything works just fine. Removing accounts-ui and adding ian:accounts-ui-bootstrap-3 will trigger an error on the server:

Exception while invoking method 'createUser' TypeError: Cannot read property 'id' of undefined
  at app/server/accounts.js:3:84
  at Object.Accounts.insertUserDoc (packages/accounts-base/accounts_server.js:1024:1)
  at createUser (packages/accounts-password/password_server.js:693:1)
  at packages/accounts-password/password_server.js:713:1
  at tryLoginMethod (packages/accounts-base/accounts_server.js:186:1)
  at Object.Accounts._loginMethod (packages/accounts-base/accounts_server.js:302:1)
  at [object Object].Meteor.methods.createUser (packages/accounts-password/password_server.js:699:1)
  at maybeAuditArgumentChecks (packages/ddp/livedata_server.js:1599:1)
  at packages/ddp/livedata_server.js:648:1
  at [object Object]._.extend.withValue (packages/meteor/dynamics_nodejs.js:56:1)

On the client side I get a Internal server error.

Here is my list of packages:

accounts-base                  1.1.3 
accounts-facebook              1.0.3 
accounts-password              1.0.6 
alanning:roles                 1.2.13  
aldeed:collection2             2.3.2 
aldeed:simple-schema           1.3.0 
fourseven:scss                 2.0.0_1 
ian:accounts-ui-bootstrap-3    1.2.33 
iron:router                    1.0.7 
matb33:collection-hooks        0.7.9 
meteor-platform                1.2.1 
meteorhacks:subs-manager       1.3.0  
mquandalle:jade                0.4.1 
multiply:iron-router-progress  1.0.1
reywood:publish-composite      1.3.5
sacha:spin                     2.0.4
twbs:bootstrap                 3.3.2
ianmartorell commented 9 years ago

Did you solve this? It's working fine for me. Can you post your createUser call?

raduchiriac commented 9 years ago

Sorry, it turned out it was an error caused by a hook I had on Accounts.onCreateUser(). Thanks