diff --git a/src/wifi.rs b/src/wifi.rs index 1103acd972a..7d32c6cfdbf 100644 --- a/src/wifi.rs +++ b/src/wifi.rs @@ -203,10 +203,7 @@ impl From> for ClientConfiguration { } else { None }, - auth_method: as std::convert::Into>>::into(Newtype( - conf.0.threshold.authmode, - )) - .unwrap(), + auth_method: Option::::from(Newtype(conf.0.threshold.authmode)).unwrap(), password: from_cstr(&conf.0.password).try_into().unwrap(), channel: if conf.0.channel != 0 { Some(conf.0.channel)