diff --git a/tools/check_crate_updates/src/manifest.rs b/tools/check_crate_updates/src/manifest.rs index df017d64..8454ddd0 100644 --- a/tools/check_crate_updates/src/manifest.rs +++ b/tools/check_crate_updates/src/manifest.rs @@ -8,7 +8,7 @@ impl Manifest { self.0 .get("dependencies") .and_then(|dep| dep.get(name)) - .map(|dep| Dependency(dep)) + .map(Dependency) } /// Gets the dependency mutably from the manifest if it exists @@ -16,11 +16,11 @@ impl Manifest { self.0 .get_mut("dependencies") .and_then(|dep| dep.get_mut(name)) - .map(|dep| DependencyMut(dep)) + .map(DependencyMut) } /// Gets the names of all the dependencies from the manifest - pub fn get_dependency_names<'a>(&'a self) -> Option> { + pub fn get_dependency_names(&self) -> Option> { self.0 .get("dependencies") .and_then(|item| item.as_table()) @@ -70,7 +70,7 @@ impl FromStr for Manifest { type Err = toml_edit::TomlError; fn from_str(s: &str) -> Result { - s.parse::().map(|doc| Manifest(doc)) + s.parse::().map(Manifest) } }