Skip to content

Commit ce999e7

Browse files
committed
spaces
1 parent 46354b0 commit ce999e7

File tree

2 files changed

+5
-11
lines changed

2 files changed

+5
-11
lines changed

Diff for: src/common.rs

-6
Original file line numberDiff line numberDiff line change
@@ -832,12 +832,6 @@ pub fn get_app_name() -> String {
832832
hbb_common::config::APP_NAME.read().unwrap().clone()
833833
}
834834

835-
#[inline]
836-
pub fn get_app_name_registry() -> String {
837-
let s = hbb_common::config::APP_NAME.read().unwrap().clone();
838-
s.split_whitespace().collect()
839-
}
840-
841835
#[inline]
842836
pub fn is_rustdesk() -> bool {
843837
hbb_common::config::APP_NAME.read().unwrap().eq("RustDesk")

Diff for: src/platform/windows.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -987,17 +987,17 @@ fn get_valid_subkey() -> String {
987987
return subkey;
988988
}
989989
let app_name = crate::get_app_name();
990-
let subkey = get_subkey(&app_name, true).replace(" ", "");
990+
let subkey = get_subkey(&app_name, true);
991991
if !get_reg_of(&subkey, "InstallLocation").is_empty() {
992992
return subkey;
993993
}
994-
return get_subkey(&app_name, false).replace(" ", "");
994+
return get_subkey(&app_name, false);
995995
}
996996

997997
// Return install options other than InstallLocation.
998998
pub fn get_install_options() -> String {
999999
let app_name = crate::get_app_name();
1000-
let subkey = format!(".{}", app_name.to_lowercase()).replace(" ", "");
1000+
let subkey = format!(".{}", app_name.to_lowercase());
10011001
let mut opts = HashMap::new();
10021002

10031003
let desktop_shortcuts = get_reg_of_hkcr(&subkey, REG_NAME_INSTALL_DESKTOPSHORTCUTS);
@@ -1135,7 +1135,7 @@ fn get_after_install(
11351135
reg_value_desktop_shortcuts: Option<String>,
11361136
) -> String {
11371137
let app_name = crate::get_app_name();
1138-
let ext = app_name.to_lowercase().replace(" ", "");
1138+
let ext = app_name.to_lowercase();
11391139

11401140
// reg delete HKEY_CURRENT_USER\Software\Classes for
11411141
// https://github.com/rustdesk/rustdesk/commit/f4bdfb6936ae4804fc8ab1cf560db192622ad01a
@@ -1358,7 +1358,7 @@ pub fn run_before_uninstall() -> ResultType<()> {
13581358

13591359
fn get_before_uninstall(kill_self: bool) -> String {
13601360
let app_name = crate::get_app_name();
1361-
let ext = app_name.to_lowercase().replace(" ", "");
1361+
let ext = app_name.to_lowercase();
13621362
let filter = if kill_self {
13631363
"".to_string()
13641364
} else {

0 commit comments

Comments
 (0)