Skip to content

Instantly share code, notes, and snippets.

@bitomule
Created July 23, 2014 10:27
Show Gist options
  • Save bitomule/f8848b1e718211143a76 to your computer and use it in GitHub Desktop.
Save bitomule/f8848b1e718211143a76 to your computer and use it in GitHub Desktop.
this.route('project',{
path: '/:_domain/projects/:_project',
onBeforeAction : 'loading',
data: function(){
return {'name':this.params._domain};
},
waitOn: function(){
var subscription = subs.subscribe('userDomain',this.params._domain,function(){
if(Domains.find().count() <= 0)
{
Router.go('register');
}
});
return [subscription];
},
onAfterAction: function(){
document.title = "Project";
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment