]> Untitled Git - lemmy.git/commitdiff
Fix historical post fetching. Fixes #2640 (#2643)
authorDessalines <dessalines@users.noreply.github.com>
Wed, 4 Jan 2023 14:58:11 +0000 (09:58 -0500)
committerGitHub <noreply@github.com>
Wed, 4 Jan 2023 14:58:11 +0000 (14:58 +0000)
crates/db_schema/src/impls/post.rs

index 2a5264402115473e1c45b3d18bac528343903725..91e7bc1e316e5456a36887afd5e86dec42ee32da 100644 (file)
@@ -82,8 +82,8 @@ impl Post {
       .filter(community_id.eq(the_community_id))
       .filter(deleted.eq(false))
       .filter(removed.eq(false))
-      .then_order_by(published.desc())
       .then_order_by(featured_community.desc())
+      .then_order_by(published.desc())
       .limit(FETCH_LIMIT_MAX)
       .load::<Self>(conn)
       .await