diff options
author | Vika <vika@fireburn.ru> | 2023-06-15 17:03:53 +0300 |
---|---|---|
committer | Vika <vika@fireburn.ru> | 2023-06-15 17:03:53 +0300 |
commit | ed7049048cc4d12422c07ddbaa15fbb3662c0260 (patch) | |
tree | 7dc37332b8868a7a7f067056026a8d662bc0571d /kittybox-rs/src/frontend/mod.rs | |
parent | eca7687439c2b6f804603de75501b6737a82e5a2 (diff) | |
download | kittybox-ed7049048cc4d12422c07ddbaa15fbb3662c0260.tar.zst |
Add support for the IndieWeb Webring πΈπ
Optional at first. Onboarding UI not yet exposed.
Diffstat (limited to 'kittybox-rs/src/frontend/mod.rs')
-rw-r--r-- | kittybox-rs/src/frontend/mod.rs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/kittybox-rs/src/frontend/mod.rs b/kittybox-rs/src/frontend/mod.rs index 9d5c164..b90d57c 100644 --- a/kittybox-rs/src/frontend/mod.rs +++ b/kittybox-rs/src/frontend/mod.rs @@ -131,10 +131,13 @@ pub async fn homepage<D: Storage>( // other requests anyway if it's serious...) // // btw is it more efficient to fetch these in parallel? - let (blogname, channels) = tokio::join!( + let (blogname, webring, channels) = tokio::join!( db.get_setting::<crate::database::settings::SiteName>(&path) .map(Result::unwrap_or_default), + db.get_setting::<crate::database::settings::Webring>(&path) + .map(Result::unwrap_or_default), + db.get_channels(&path).map(|i| i.unwrap_or_default()) ); // Render the homepage @@ -152,6 +155,7 @@ pub async fn homepage<D: Storage>( content: MainPage { feed: &hfeed, card: &hcard, + webring: crate::database::settings::Setting::into_inner(webring) } .to_string(), } |