From 68d247388fc7d866a67d9cf1f16e7aa0bebd3213 Mon Sep 17 00:00:00 2001 From: Max Goodman Date: Wed, 10 Apr 2013 17:39:39 -0700 Subject: [PATCH] Only show the listing chooser on html pages. This fixes a listing chooser template error on non-html styles. --- r2/r2/controllers/listingcontroller.py | 1 + 1 file changed, 1 insertion(+) diff --git a/r2/r2/controllers/listingcontroller.py b/r2/r2/controllers/listingcontroller.py index 0a40b0208..41c8c78eb 100755 --- a/r2/r2/controllers/listingcontroller.py +++ b/r2/r2/controllers/listingcontroller.py @@ -116,6 +116,7 @@ class ListingController(RedditController, OAuth2ResourceController): content = self.content() page_classes = self.extra_page_classes if (self.show_chooser and + c.render_style == "html" and c.user_is_loggedin and c.user.pref_show_left_bar and isinstance(c.site, (DefaultSR, AllSR, LabeledMulti))): page_classes = page_classes + ['with-listing-chooser']