Make Account Center only usable when logged in
[blerg.git] / www / jssrc / blerg / Blerg.js
index 4a95114..944c0c1 100644 (file)
@@ -5,7 +5,7 @@ enyo.kind({
     name: "blerg.Blerg",
     kind: "Control",
     lastHash: null,
-    pathHandlers: [ blerg.User, blerg.Tag, blerg.Feed, blerg.ExternalURLPost, blerg.Welcome, blerg.AccountCenter, blerg.Recovery ],
+    pathHandlers: [ blerg.User, blerg.Tag, blerg.Feed, blerg.ExternalURLPost, blerg.Welcome, blerg.AccountCenter, blerg.Recovery, blerg.EmailVerify ],
     handlers: {
         onStartSignup: "showSignupDialog",
         onTryLogin: "tryLogin",
@@ -26,7 +26,6 @@ enyo.kind({
         ]},
         {name: "main", kind: "blerg.Main"},
         {name: "signupDialog", kind: "blerg.SignupDialog"},
-        {name: "passwdDialog", kind: "blerg.PasswdDialog"},
         {name: "api", kind: "blerg.API",
          onLoginSuccessful: "loginSuccessful",
          onLoginFailed: "loginFailed",
@@ -85,6 +84,7 @@ enyo.kind({
     },
     loginFailed: function(inSender, inEvent) {
         alert('Login failed');
+        this.waterfall('onShowForgotPasswordLink');
         this.logout();
     },
     logout: function(inSender, inEvent) {
@@ -98,9 +98,6 @@ enyo.kind({
     sendReload: function() {
         this.$.main.waterfall('onReload');
     },
-    showChangePassword: function() {
-        this.$.passwdDialog.show();
-    },
     authFailure: function(inSender, inEvent) {
         this.logout();
     }