mirror of
https://github.com/rustdesk/hbb_common.git
synced 2026-04-03 06:26:30 +00:00
fix(password): remove unnecessary check
Signed-off-by: fufesou <linlong1266@gmail.com>
This commit is contained in:
@@ -1276,17 +1276,6 @@ impl Config {
|
||||
salt: &str,
|
||||
) -> crate::ResultType<bool> {
|
||||
let mut config = CONFIG.write().unwrap();
|
||||
|
||||
if storage.is_empty() {
|
||||
if config.password.is_empty() {
|
||||
return Ok(false);
|
||||
}
|
||||
config.password = String::new();
|
||||
config.store();
|
||||
Self::clear_trusted_devices();
|
||||
return Ok(true);
|
||||
}
|
||||
|
||||
if config.password == storage && config.salt == salt {
|
||||
return Ok(false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user