Merge pull request #401 from matthiasbeyer/libimagutil/code-cleanup
Code cleanup in libimagutil
This commit is contained in:
commit
11021906b3
1 changed files with 2 additions and 10 deletions
|
@ -56,18 +56,10 @@ impl IntoKeyValue<String, String> for String {
|
|||
.unwrap();
|
||||
}
|
||||
R.captures(&self[..])
|
||||
.map(|caps| {
|
||||
caps.name("VALUE")
|
||||
.or(caps.name("QVALUE"))
|
||||
.unwrap_or("")
|
||||
})
|
||||
.map(|caps| caps.name("VALUE").or(caps.name("QVALUE")).unwrap_or(""))
|
||||
};
|
||||
|
||||
key.and_then(|k| {
|
||||
value.and_then(|v| {
|
||||
Some(KeyValue::new(String::from(k), String::from(v)))
|
||||
})
|
||||
})
|
||||
key.and_then(|k| value.and_then(|v| Some(KeyValue::new(String::from(k), String::from(v)))))
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue