fix clippy errors for rust 1.74
This commit is contained in:
parent
7ca6cc8dfa
commit
1526d15768
@ -493,7 +493,7 @@ impl DefineBitcoind {
|
||||
let builder = match selected_auth_type {
|
||||
RpcAuthType::CookieFile => {
|
||||
let cookie_path = rpc_auth_vals.cookie_path.value;
|
||||
let cookie = std::fs::read_to_string(&cookie_path).map_err(|e| {
|
||||
let cookie = std::fs::read_to_string(cookie_path).map_err(|e| {
|
||||
Error::Bitcoind(format!("Failed to read cookie file: {}", e))
|
||||
})?;
|
||||
SimpleHttpTransport::builder().cookie_auth(cookie)
|
||||
|
||||
@ -719,7 +719,7 @@ impl EditXpubModal {
|
||||
.name
|
||||
.clone()
|
||||
})
|
||||
.unwrap_or_else(String::new),
|
||||
.unwrap_or_default(),
|
||||
},
|
||||
form_xpub: form::Value {
|
||||
valid: true,
|
||||
@ -731,7 +731,7 @@ impl EditXpubModal {
|
||||
.key
|
||||
.to_string()
|
||||
})
|
||||
.unwrap_or_else(String::new),
|
||||
.unwrap_or_default(),
|
||||
},
|
||||
keys,
|
||||
path_index,
|
||||
|
||||
@ -1621,14 +1621,14 @@ pub fn key_list_view<'a>(
|
||||
) -> Element<'a, Message> {
|
||||
let bttn = Button::new(if chosen {
|
||||
hw::selected_hardware_wallet(
|
||||
kind.map(|k| k.to_string()).unwrap_or_else(String::new),
|
||||
kind.map(|k| k.to_string()).unwrap_or_default(),
|
||||
None::<String>,
|
||||
fingerprint,
|
||||
Some(name),
|
||||
)
|
||||
} else {
|
||||
hw::supported_hardware_wallet(
|
||||
kind.map(|k| k.to_string()).unwrap_or_else(String::new),
|
||||
kind.map(|k| k.to_string()).unwrap_or_default(),
|
||||
None::<String>,
|
||||
fingerprint,
|
||||
Some(name),
|
||||
|
||||
@ -95,7 +95,6 @@ impl Loader {
|
||||
.daemon_rpc_path
|
||||
.clone()
|
||||
.unwrap_or_else(|| socket_path(&datadir_path, network));
|
||||
let network = network;
|
||||
(
|
||||
Loader {
|
||||
network,
|
||||
@ -321,7 +320,6 @@ impl Loader {
|
||||
let reader = BufReader::new(file);
|
||||
let last_update_tip = reader
|
||||
.lines()
|
||||
.into_iter()
|
||||
.filter(|l| {
|
||||
l.as_ref()
|
||||
.map(|l| l.contains("UpdateTip") || l.contains("blockheaders"))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user