ianmartorell / meteor-accounts-ui-bootstrap-3

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

Is there a notification on account creation? #47

Closed Obiwarn closed 9 years ago

Obiwarn commented 9 years ago

So I can show an alert or sth. to the user that he/she needs to verify the email address.

newswim commented 9 years ago

:+1:

reustle commented 9 years ago

While I don't have the answer for you, this (server side) method might be helpful

http://docs.meteor.com/#/full/accounts_oncreateuser

ianmartorell commented 9 years ago

You could do something like this:

Meteor.autorun(function(){
  var user = Meteor.user();
  if (!user || !user.profile) return;
  if (!user.emails[0].verified) {
    // Show an alert or something
  }
});

This would prompt the user to verify the email address on every login, or you could modify it so it instead checks for a different flag and sets it to true the first time it runs.

dandv commented 9 years ago

This seems out of scope for this package?

ianmartorell commented 9 years ago

Yeah