Closed Nisthar closed 6 years ago
Hi,
First you need to understand that Accounts.createUser isn't an Meteor.users.insert
.
Then that your schema is compatible with Meteor.users
which doesn't need the same arguments than Accounts.createUser
.
Finally if you want to use a schema for Accounts.createUser
you need to create a specific schema for it.
Ok
On Thu, Apr 28, 2016 at 2:19 PM, darkship notifications@github.com wrote:
Hi, First you need to understand that Accounts.createUser http://docs.meteor.com/#/full/accounts_createuser isn't an Meteor.users.insert.
Then that your schema is compatible with Meteor.users which doesn't need the same arguments than Accounts.createUser.
Finally if you want to use a schema for Accounts.createUser you need to create a specific schema for it.
— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/aldeed/meteor-collection2/issues/324#issuecomment-215355742
Closing old issues. Please comment if this is still an issue and should be reopened.
I am new to meteor and simple schema. I find it very confusing and difficult to use as meteor is slightly different than other frameworks. I am getting "Password is not allowed by the schema" error. I know its because there is no password field in my schema. But I used the code from the collection2 official doc.
my code:
My schema: `Schema.User = new SimpleSchema({ username: { type: String, },
});
Meteor.users.attachSchema(Schema.User);`