fix: Speedtest not registering number of bytes read

This commit is contained in:
quexeky
2026-01-25 22:07:50 +11:00
parent 8c8e9ad4c9
commit bb3280cedf
10 changed files with 90 additions and 51 deletions
+3 -3
View File
@@ -8,7 +8,7 @@ macro_rules! interactive_variable {
let $var = if let Some($var) = $value.$var {
$var
} else {
crate::commands::connect::interactive::query_variable($prompt).unwrap()
$crate::commands::connect::interactive::query_variable($prompt).unwrap()
};
};
}
@@ -18,7 +18,7 @@ macro_rules! interactive_optional_variable {
let $var = if let Some($var) = $value.$var {
Some($var)
} else {
crate::commands::connect::interactive::query_optional_variable($prompt).unwrap()
$crate::commands::connect::interactive::query_optional_variable($prompt).unwrap()
};
};
}
@@ -40,7 +40,7 @@ where
.with_prompt(prompt.to_string())
.allow_empty(true)
.interact_text()?;
if input.to_string().len() == 0 {
if input.to_string().is_empty() {
return Ok(None);
}
Ok(Some(input))