Skip to content

Commit

Permalink
Resolve Clippy Warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
killercup committed Oct 10, 2015
1 parent a5325d5 commit 173fd39
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/manifest.rs
Expand Up @@ -137,15 +137,16 @@ impl Manifest {
}

/// Add entry to a Cargo.toml.
#[cfg_attr(feature = "dev", allow(toplevel_ref_arg))]
fn insert_into_table(&mut self,
table: &str,
&(ref name, ref data): &Dependency)
-> Result<(), ManifestError> {
let ref mut manifest = self.data;
let entry = manifest.entry(String::from(table))
.or_insert(toml::Value::Table(BTreeMap::new()));
match entry {
&mut toml::Value::Table(ref mut deps) => {
match *entry {
toml::Value::Table(ref mut deps) => {
deps.insert(name.clone(), data.clone());
Ok(())
}
Expand Down

0 comments on commit 173fd39

Please sign in to comment.