From c28f449476d1047042b4e1afabce936c11c01283 Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Sat, 24 Jul 2021 23:23:10 +0200 Subject: [PATCH] df --- drama/helpers/get.py | 5 +++-- drama/templates/submission_listing.html | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/drama/helpers/get.py b/drama/helpers/get.py index 0186495a3..8506b9ff1 100644 --- a/drama/helpers/get.py +++ b/drama/helpers/get.py @@ -173,14 +173,15 @@ def get_posts(pids, sort="hot", v=None): output[i]._voted = query[i][1] or 0 output[i]._is_blocking = query[i][2] or 0 output[i]._is_blocked = query[i][3] or 0 + return output else: query = g.db.query( - Submission, + Submission ).filter(Submission.id.in_(pids) ).order_by(Submission.id).all() - return query + return query def get_post_with_comments(pid, sort="top", v=None): diff --git a/drama/templates/submission_listing.html b/drama/templates/submission_listing.html index 77aa775fa..968c66403 100644 --- a/drama/templates/submission_listing.html +++ b/drama/templates/submission_listing.html @@ -9,8 +9,8 @@ {% endif %} -{% set ups=p.upvotes %} -{% set downs=p.downvotes %} +{% set ups=p.upvotes_fuzzed %} +{% set downs=p.downvotes_fuzzed %} {% set score=ups-downs %} {% if v %}