mirror of
https://github.com/weyne85/rustdesk.git
synced 2025-10-29 17:00:05 +00:00
@@ -122,6 +122,7 @@ pub fn session_add_sync(
|
||||
switch_uuid: String,
|
||||
force_relay: bool,
|
||||
password: String,
|
||||
is_shared_password: bool,
|
||||
) -> SyncReturn<String> {
|
||||
if let Err(e) = session_add(
|
||||
&session_id,
|
||||
@@ -132,6 +133,7 @@ pub fn session_add_sync(
|
||||
&switch_uuid,
|
||||
force_relay,
|
||||
password,
|
||||
is_shared_password,
|
||||
) {
|
||||
SyncReturn(format!("Failed to add session with id {}, {}", &id, e))
|
||||
} else {
|
||||
@@ -1018,14 +1020,6 @@ pub fn main_load_lan_peers_sync() -> SyncReturn<String> {
|
||||
return SyncReturn(serde_json::ser::to_string(&data).unwrap_or("".to_owned()));
|
||||
}
|
||||
|
||||
pub fn main_load_ab_sync() -> SyncReturn<String> {
|
||||
return SyncReturn(serde_json::to_string(&config::Ab::load()).unwrap_or_default());
|
||||
}
|
||||
|
||||
pub fn main_load_group_sync() -> SyncReturn<String> {
|
||||
return SyncReturn(serde_json::to_string(&config::Group::load()).unwrap_or_default());
|
||||
}
|
||||
|
||||
pub fn main_load_recent_peers_for_ab(filter: String) -> String {
|
||||
let id_filters = serde_json::from_str::<Vec<String>>(&filter).unwrap_or_default();
|
||||
let id_filters = if id_filters.is_empty() {
|
||||
|
||||
Reference in New Issue
Block a user