fix some warnings

This commit is contained in:
Carson McManus 2022-06-19 13:01:25 -04:00
parent 0b84a103e5
commit c86e31648a

View file

@ -11,7 +11,7 @@ use steamguard::{
SteamGuardAccount, UserLogin, SteamGuardAccount, UserLogin,
}; };
use crate::{accountmanager::ManifestAccountLoadError}; use crate::accountmanager::ManifestAccountLoadError;
#[macro_use] #[macro_use]
extern crate lazy_static; extern crate lazy_static;
@ -135,7 +135,7 @@ fn run() -> anyhow::Result<()> {
_ => {}, _ => {},
} }
let mut selected_accounts: Vec<Arc<Mutex<SteamGuardAccount>>>; let selected_accounts: Vec<Arc<Mutex<SteamGuardAccount>>>;
loop { loop {
match get_selected_accounts(&args, &mut manifest) { match get_selected_accounts(&args, &mut manifest) {
Ok(accounts) => { Ok(accounts) => {
@ -529,7 +529,7 @@ fn do_subcmd_trade(args: cli::ArgsTrade, manifest: &mut accountmanager::Manifest
return Ok(()); return Ok(());
} }
fn do_subcmd_remove(args: cli::ArgsRemove, manifest: &mut accountmanager::Manifest, selected_accounts: Vec<Arc<Mutex<SteamGuardAccount>>>) -> anyhow::Result<()> { fn do_subcmd_remove(_args: cli::ArgsRemove, manifest: &mut accountmanager::Manifest, selected_accounts: Vec<Arc<Mutex<SteamGuardAccount>>>) -> anyhow::Result<()> {
println!( println!(
"This will remove the mobile authenticator from {} accounts: {}", "This will remove the mobile authenticator from {} accounts: {}",
selected_accounts.len(), selected_accounts.len(),
@ -589,7 +589,7 @@ fn do_subcmd_remove(args: cli::ArgsRemove, manifest: &mut accountmanager::Manife
return Ok(()); return Ok(());
} }
fn do_subcmd_encrypt(args: cli::ArgsEncrypt, manifest: &mut accountmanager::Manifest) -> anyhow::Result<()> { fn do_subcmd_encrypt(_args: cli::ArgsEncrypt, manifest: &mut accountmanager::Manifest) -> anyhow::Result<()> {
if !manifest.has_passkey() { if !manifest.has_passkey() {
let mut passkey; let mut passkey;
loop { loop {
@ -611,7 +611,7 @@ fn do_subcmd_encrypt(args: cli::ArgsEncrypt, manifest: &mut accountmanager::Mani
return Ok(()); return Ok(());
} }
fn do_subcmd_decrypt(args: cli::ArgsDecrypt, manifest: &mut accountmanager::Manifest) -> anyhow::Result<()> { fn do_subcmd_decrypt(_args: cli::ArgsDecrypt, manifest: &mut accountmanager::Manifest) -> anyhow::Result<()> {
manifest.load_accounts()?; manifest.load_accounts()?;
for entry in &mut manifest.entries { for entry in &mut manifest.entries {
entry.encryption = None; entry.encryption = None;