Moved initialize function to Router.
Fixed bug that can not sign in.