+#[macro_use]
+extern crate lazy_static;
+
pub mod activities;
pub mod activity_queue;
pub mod comment;
pub mod private_message;
pub mod user;
-use crate::{
- apub::extensions::{
- group_extensions::GroupExtension,
- page_extension::PageExtension,
- signatures::{PublicKey, PublicKeyExtension},
- },
- request::{retry, RecvError},
- routes::webfinger::WebFingerResponse,
- DbPool,
- LemmyContext,
+use crate::extensions::{
+ group_extensions::GroupExtension,
+ page_extension::PageExtension,
+ signatures::{PublicKey, PublicKeyExtension},
};
use activitystreams::{
activity::Follow,
use actix_web::{body::Body, HttpResponse};
use anyhow::{anyhow, Context};
use chrono::NaiveDateTime;
-use lemmy_db::{activity::do_insert_activity, user::User_};
-use lemmy_structs::blocking;
+use lemmy_db::{activity::do_insert_activity, user::User_, DbPool};
+use lemmy_structs::{blocking, WebFingerResponse};
use lemmy_utils::{
apub::get_apub_protocol_string,
location_info,
+ request::{retry, RecvError},
settings::Settings,
utils::{convert_datetime, MentionData},
LemmyError,
};
+use lemmy_websocket::LemmyContext;
use log::debug;
use reqwest::Client;
use serde::Serialize;
async fn send_undo_remove(&self, mod_: &User_, context: &LemmyContext) -> Result<(), LemmyError>;
}
-pub(in crate::apub) fn check_actor_domain<T, Kind>(
+pub(in crate) fn check_actor_domain<T, Kind>(
apub: &T,
expected_domain: Option<Url>,
) -> Result<String, LemmyError>