我尝试创建用户注册。我有安装
accounts-base 1.2.2* A user account system
accounts-password 1.1.4* Password support for accounts
在客户端:
var userNew = {
password: textPassword,
username: textUserName,
profile: {
address: textAddress
}
};
Accounts.createUser(userNew, function (err) {
if (err) {
alert(err.message);
} else {
Router.go('/');
}
});
但显示错误:
I20160423-17:47:07.299(7)? Exception while invoking method 'createUser' TypeError: Cannot read property 'accessToken' of undefined
我也在服务器端设置:
Accounts.config({
forbidClientAccountCreation : false
});