From 3bdfdd7c047bc71008a9c3432e828e16d5b4c243 Mon Sep 17 00:00:00 2001 From: Chris Hunt Date: Fri, 7 Jun 2013 22:09:51 -0700 Subject: [PATCH] Redirect when can_edit === false or undefined --- .../discourse/routes/discourse_restricted_user_route.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/routes/discourse_restricted_user_route.js b/app/assets/javascripts/discourse/routes/discourse_restricted_user_route.js index dbd73f4b906..3d522071a74 100644 --- a/app/assets/javascripts/discourse/routes/discourse_restricted_user_route.js +++ b/app/assets/javascripts/discourse/routes/discourse_restricted_user_route.js @@ -9,7 +9,7 @@ Discourse.RestrictedUserRoute = Discourse.Route.extend({ redirect: function(user) { - if (user.get('can_edit') === false) { + if (!user.get('can_edit')) { this.transitionTo('user.activity', user); } }