Open nilnullzip opened 8 years ago
I do mine like this:
FlowRouter.triggers.enter([function(context, redirect){
if(!Meteor.userId()) {
FlowRouter.go('login');
}
}], {except: [
"sign-up",
"login",
"LandingPage",
]});
Did you try it with the "name" of the "/" route instead of the url path? so, name the "/" path somethign like "home" or "login" and pass that in?
I can't seem to get the triggers except option working. This example should not invoke loginCheck() when visiting the '/' route. However the console.log message is always printed.