From 7e52cf0e0988fa639bf62e33698b48f000cabb73 Mon Sep 17 00:00:00 2001 From: Brian Simpson Date: Fri, 9 Aug 2013 14:49:19 -0400 Subject: [PATCH] Accept reports on promoted links. --- r2/r2/controllers/api.py | 2 -- r2/r2/lib/pages/things.py | 4 +--- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/r2/r2/controllers/api.py b/r2/r2/controllers/api.py index 051580d40..0ef600f4f 100755 --- a/r2/r2/controllers/api.py +++ b/r2/r2/controllers/api.py @@ -1208,8 +1208,6 @@ class ApiController(RedditController, OAuth2ResourceController): """ if not thing or thing._deleted: return - elif getattr(thing, 'promoted', False): - return # if it is a message that is being reported, ban it. # every user is admin over their own personal inbox diff --git a/r2/r2/lib/pages/things.py b/r2/r2/lib/pages/things.py index 5cf585dbb..70effa99a 100644 --- a/r2/r2/lib/pages/things.py +++ b/r2/r2/lib/pages/things.py @@ -70,9 +70,7 @@ class LinkButtons(PrintableButtons): is_author = (c.user_is_loggedin and thing.author and c.user.name == thing.author.name) # do we show the report button? - show_report = (not is_author and - report and - getattr(thing, "promoted", None) is None) + show_report = not is_author and report if c.user_is_admin and thing.promoted is None: show_report = False