router problems
This commit is contained in:
parent
793a7ce03f
commit
2fc96ef4f9
@ -1,8 +1,5 @@
|
||||
function completeProfile() {
|
||||
if (Meteor.user().profile.school &&
|
||||
Meteor.user().profile.grade &&
|
||||
Meteor.user().profile.classes.length > 1 &&
|
||||
Meteor.user().profile.complete) {
|
||||
if (Meteor.user().profile.complete) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
@ -12,8 +9,6 @@ function completeProfile() {
|
||||
Router.route('/', {
|
||||
waitOn: function() {
|
||||
if (!Meteor.userId() || !completeProfile()) {
|
||||
console.log("hello")
|
||||
console.log(completeProfile());
|
||||
this.redirect('/login');
|
||||
} else {
|
||||
return [
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user