From 21fb8f84be99d30fa1700746d9d5931a8774c1f0 Mon Sep 17 00:00:00 2001 From: Neil Williams Date: Thu, 30 May 2013 18:31:12 -0700 Subject: [PATCH] Temporary bandaid for top bar breaking various subreddits. sr_pops has put certain subreddits into the top subreddit list multiple times. This causes there to be multiple buttons in the srbar. The sort logic in NavMenu.find_selected short circuited when the lists were of length 1, but now that they aren't it's dying rightfully on this attribute not existing on SubredditButton. This is a temporary patch to help until the sr_pops issue is fixed. --- r2/r2/lib/menus.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/r2/r2/lib/menus.py b/r2/r2/lib/menus.py index 5e8657728..864b38adf 100644 --- a/r2/r2/lib/menus.py +++ b/r2/r2/lib/menus.py @@ -352,7 +352,7 @@ class SubredditButton(NavButton): isselected = (c.site == sr), **kw) def build(self, base_path = ''): - pass + self.bare_path = "" def is_selected(self): return self.isselected