meteor-useraccounts/core — pull request #198 by fpoirier1 (2014-12-11 21:13:22+00:00)
Title: added onSuccess callback from template helper

Basically, all we have to do is to specify a onSuccess callback like this `{{> atForm onSuccess=onSuccess}}`. The callback can looks something similar to this :

var closeModal = function(){
// ...
AccountsTemplates.avoidRedirect = true; // will prevent the redirection
$("#modal").modal('hide');
}

Template.modal.helpers({
onSuccess : function(){
return closeModal;
}
});