use crate::sensitive::Sensitive;
use lemmy_db_schema::{
newtypes::{CommentId, CommunityId, LanguageId, PersonId, PostId},
- source::{
- instance::Instance,
- language::Language,
- local_site::RegistrationMode,
- tagline::Tagline,
- },
+ source::{instance::Instance, language::Language, tagline::Tagline},
ListingType,
ModlogActionType,
+ RegistrationMode,
SearchType,
SortType,
};
pub application_question: Option<String>,
pub private_instance: Option<bool>,
pub default_theme: Option<String>,
- pub default_post_listing_type: Option<String>,
+ pub default_post_listing_type: Option<ListingType>,
pub legal_information: Option<String>,
pub application_email_admins: Option<bool>,
pub hide_modlog_mod_names: Option<bool>,
pub application_question: Option<String>,
pub private_instance: Option<bool>,
pub default_theme: Option<String>,
- pub default_post_listing_type: Option<String>,
+ pub default_post_listing_type: Option<ListingType>,
pub legal_information: Option<String>,
pub application_email_admins: Option<bool>,
pub hide_modlog_mod_names: Option<bool>,
pub online: usize,
pub version: String,
pub my_user: Option<MyUserInfo>,
- pub federated_instances: Option<FederatedInstances>, // Federation may be disabled
pub all_languages: Vec<Language>,
pub discussion_languages: Vec<LanguageId>,
pub taglines: Vec<Tagline>,
pub custom_emojis: Vec<CustomEmojiView>,
}
+#[derive(Debug, Serialize, Deserialize, Clone)]
+pub struct GetFederatedInstances {}
+
+#[derive(Debug, Serialize, Deserialize, Clone)]
+pub struct GetFederatedInstancesResponse {
+ pub federated_instances: Option<FederatedInstances>, // Federation may be disabled
+}
+
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct MyUserInfo {
pub local_user_view: LocalUserView,