javascript - Collection2 validation context not working in Accounts.createUser -
i developing app in meteor. have customized registration form. using collection2 , simple schema client/server validation.
problem:- when write following code in client side it's shows me error of callback not function.
accounts.createuser(newuser,{validationcontext: 'insertform'}, function(error,result){ if(!error){ alert('yey'); } });
error: typeerror: callback not function
account...506dd40 (line 151)
here helper code want store errors.
template.signup.helpers({ errors:function(){ var context = meteor.users.simpleschema().namedcontext('insertform'); return context.invalidkeys().map(function(data){ return {message: context.keyerrormessage(data.name)}}); } });
Comments
Post a Comment