mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2024-11-22 13:29:21 +00:00
Move a field
This commit is contained in:
parent
2f931ff026
commit
53446ab8a6
@ -19,9 +19,11 @@ pub struct GeneralSettingsAPI {
|
|||||||
allow_posts_from_friends: bool,
|
allow_posts_from_friends: bool,
|
||||||
allow_comunic_mails: bool,
|
allow_comunic_mails: bool,
|
||||||
public_friends_list: bool,
|
public_friends_list: bool,
|
||||||
|
public_email: bool,
|
||||||
virtual_directory: String,
|
virtual_directory: String,
|
||||||
personnal_website: String,
|
personnal_website: String,
|
||||||
publicNote: String,
|
publicNote: String,
|
||||||
|
location: Option<String>,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl GeneralSettingsAPI {
|
impl GeneralSettingsAPI {
|
||||||
@ -37,9 +39,11 @@ impl GeneralSettingsAPI {
|
|||||||
allow_posts_from_friends: user.allow_posts_from_friends,
|
allow_posts_from_friends: user.allow_posts_from_friends,
|
||||||
allow_comunic_mails: user.allow_mails,
|
allow_comunic_mails: user.allow_mails,
|
||||||
public_friends_list: user.public_friends_list,
|
public_friends_list: user.public_friends_list,
|
||||||
|
public_email: user.is_email_public,
|
||||||
virtual_directory: user.virtual_directory.clone().unwrap_or(String::new()),
|
virtual_directory: user.virtual_directory.clone().unwrap_or(String::new()),
|
||||||
personnal_website: user.personal_website.clone().unwrap_or(String::new()),
|
personnal_website: user.personal_website.clone().unwrap_or(String::new()),
|
||||||
publicNote: user.public_note.clone().unwrap_or(String::new()),
|
publicNote: user.public_note.clone().unwrap_or(String::new()),
|
||||||
|
location: user.location.clone(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -31,7 +31,6 @@ pub struct APIAdvancedInfo {
|
|||||||
personnalWebsite: String,
|
personnalWebsite: String,
|
||||||
publicNote: String,
|
publicNote: String,
|
||||||
location: Option<String>,
|
location: Option<String>,
|
||||||
is_email_public: bool,
|
|
||||||
email_address: Option<String>,
|
email_address: Option<String>,
|
||||||
noCommentOnHisPage: bool,
|
noCommentOnHisPage: bool,
|
||||||
allowPostFromFriendOnHisPage: bool,
|
allowPostFromFriendOnHisPage: bool,
|
||||||
@ -87,7 +86,6 @@ impl APIUserInfo {
|
|||||||
personnalWebsite: info.personal_website.clone().unwrap_or(String::new()),
|
personnalWebsite: info.personal_website.clone().unwrap_or(String::new()),
|
||||||
publicNote: info.public_note.clone().unwrap_or(String::new()),
|
publicNote: info.public_note.clone().unwrap_or(String::new()),
|
||||||
location: info.location.clone(),
|
location: info.location.clone(),
|
||||||
is_email_public: info.is_email_public,
|
|
||||||
email_address: match info.is_email_public {
|
email_address: match info.is_email_public {
|
||||||
true => Some(info.email.clone()),
|
true => Some(info.email.clone()),
|
||||||
false => None,
|
false => None,
|
||||||
|
Loading…
Reference in New Issue
Block a user