diff --git a/src/modules/package.rs b/src/modules/package.rs index 5edacd21..c459323d 100644 --- a/src/modules/package.rs +++ b/src/modules/package.rs @@ -60,11 +60,11 @@ fn extract_poetry_version(file_contents: &str) -> Option { fn get_package_version() -> Option { if let Ok(cargo_toml) = utils::read_file("Cargo.toml") { - return extract_cargo_version(&cargo_toml); + extract_cargo_version(&cargo_toml) } else if let Ok(package_json) = utils::read_file("package.json") { - return extract_package_version(&package_json); + extract_package_version(&package_json) } else if let Ok(poetry_toml) = utils::read_file("pyproject.toml") { - return extract_poetry_version(&poetry_toml); + extract_poetry_version(&poetry_toml) } else { None }