move WhoAmI to sbot module

This commit is contained in:
glyph 2022-08-11 17:34:02 +01:00
parent 1d80f0a24e
commit ebc6fea762
2 changed files with 4 additions and 4 deletions

View File

@ -119,10 +119,7 @@ use rocket::{
use rocket_dyn_templates::Template;
use xdg::BaseDirectories;
use crate::{db::Database, routes::*, task_loop::Task};
/// The public key of the local sbot instance.
pub struct WhoAmI(String);
use crate::{db::Database, routes::*, sbot::WhoAmI, task_loop::Task};
#[launch]
async fn rocket() -> _ {

View File

@ -15,6 +15,9 @@ use serde_json::value::Value;
use crate::db::Post;
/// The public key of the local sbot instance.
pub struct WhoAmI(pub String);
/// Initialise a connection to a Scuttlebutt server.
async fn init_sbot() -> Result<Sbot, String> {
// Define the port on which the go-sbot is running.