tangled
alpha
login
or
join now
parakeet.at
/
parakeet
63
fork
atom
Parakeet is a Rust-based Bluesky AppServer aiming to implement most of the functionality required to support the Bluesky client
appview
atproto
bluesky
rust
appserver
63
fork
atom
overview
issues
12
pulls
pipelines
fix(parakeet): return the correct goddamn threadgate
mia.omg.lol
4 months ago
6002d4ed
7cd2ac36
verified
This commit was signed with the committer's
known signature
.
mia.omg.lol
SSH Key Fingerprint:
SHA256:eb+NhC0QEl+XKRuFP/97oH6LEz0TXTKPXGDIAI5y7CQ=
+4
-1
1 changed file
expand all
collapse all
unified
split
parakeet
src
loaders.rs
+4
-1
parakeet/src/loaders.rs
···
4
4
use dataloader::async_cached::Loader;
5
5
use dataloader::non_cached::Loader as NonCachedLoader;
6
6
use dataloader::BatchFn;
7
7
+
use diesel::dsl::sql;
7
8
use diesel::prelude::*;
8
9
use diesel_async::pooled_connection::deadpool::Pool;
9
10
use diesel_async::{AsyncPgConnection, RunQueryDsl};
···
368
369
let mut conn = self.0.get().await.unwrap();
369
370
370
371
let res = schema::posts::table
371
371
-
.left_join(schema::threadgates::table)
372
372
+
.left_join(schema::threadgates::table.on(
373
373
+
schema::threadgates::post_uri.eq(sql("coalesce(posts.root_uri, posts.at_uri)")),
374
374
+
))
372
375
.select((
373
376
models::Post::as_select(),
374
377
Option::<models::Threadgate>::as_select(),