diff --git a/files/routes/users.py b/files/routes/users.py index 3c3753cfbe..5b0dbf3ea7 100644 --- a/files/routes/users.py +++ b/files/routes/users.py @@ -175,7 +175,7 @@ def upvoters_downvoters(v, username, username2, cls, vote_cls, vote_dir, templat ) if cls == Post: - listing = listing.filter_by(draft=False) + listing = listing.filter(cls.draft == False) total = listing.count() @@ -241,7 +241,7 @@ def upvoting_downvoting(v, username, username2, cls, vote_cls, vote_dir, templat ) if cls == Post: - listing = listing.filter_by(draft=False) + listing = listing.filter(cls.draft == False) total = listing.count()