Permalink
Browse files

Show a loading screen while waiting to login.

chapter7-4
  • Loading branch information...
tmeasday committed Apr 7, 2013
1 parent 10eac50 commit 700ecc42e640405e5d963daca1514a168c09a52d
Showing with 5 additions and 1 deletion.
  1. +5 −1 lib/router.js
View
@@ -16,7 +16,11 @@ Router.route('/submit', {name: 'postSubmit'});
var requireLogin = function() {
if (! Meteor.user()) {
this.render('accessDenied');
if (Meteor.loggingIn()) {
this.render(this.loadingTemplate);
} else {
this.render('accessDenied');
}
} else {
this.next();
}

4 comments on commit 700ecc4

@chengguozhen

This comment has been minimized.

Show comment
Hide comment

good

@tete1230

This comment has been minimized.

Show comment
Hide comment

very good

@asdimchik

This comment has been minimized.

Show comment
Hide comment
@asdimchik

asdimchik Aug 17, 2016

very very good )

very very good )

@ShineKidd

This comment has been minimized.

Show comment
Hide comment
@ShineKidd

ShineKidd Jul 17, 2017

very very very good :) 👍

very very very good :) 👍

Please sign in to comment.