1 use lemmy_utils::settings::structs::Settings;
2 use url::{ParseError, Url};
5 pub(crate) mod comment;
6 pub(crate) mod community;
8 pub(crate) mod private_message;
11 /// Generate a unique ID for an activity, in the format:
12 /// `http(s)://example.com/receive/create/202daf0a-1489-45df-8d2e-c8a3173fed36`
13 fn generate_activity_id<T>(kind: T) -> Result<Url, ParseError>
18 "{}/activities/{}/{}",
19 Settings::get().get_protocol_and_hostname(),
20 kind.to_string().to_lowercase(),