chore: Lint rs partially

This commit is contained in:
LynithDev 2024-12-08 15:27:19 +01:00
parent 2bdfd50e36
commit 3e9605997b
4 changed files with 5 additions and 5 deletions

View file

@ -10,5 +10,5 @@ fn main() {
dbg!(hash);
dbg!(hash as u64);
assert_eq!(hash, 661461369);
assert_eq!(hash, 661_461_369);
}

View file

@ -36,8 +36,8 @@ pub async fn find_managed_version(
Ok(versions.0
.iter()
.find(|v| {
if package_version.is_some() {
return v.id == *package_version.as_ref().unwrap();
if let Some(package_version) = package_version.as_ref() {
return v.id == *package_version;
}
let check_game_version = game_version

View file

@ -144,7 +144,7 @@ impl State {
}?;
send_ingress(&ingress, 5.0, Some("loading packages")).await?;
let packages = Packages::initialize(&clusters).await;
let packages = Packages::initialize(&clusters);
let ingress_processor = IngressProcessor::new();
let discord_rpc = DiscordRPC::initialize(is_offline || settings.disable_discord)?;

View file

@ -200,7 +200,7 @@ pub struct Packages {
}
impl Packages {
pub async fn initialize(clusters: &Clusters) -> Self {
pub fn initialize(clusters: &Clusters) -> Self {
let mut this = Self { managers: HashMap::new() };
// TODO: This should probably not clone and store the cluster path in like 2 areas