test(anatomy): clippy collapse in the sanitiser oracle test
This commit is contained in:
1 parent
85c2183791
commit
ab41084a36
1 file changed
+4
-4
@@ -77,10 +77,10 @@ fn tree_value(element: &Element) -> Value {
|
||||
|
||||
/// Removes the named attribute from every element of that local name (a declared removal).
|
||||
fn strip(tree: &mut Value, element: &str, attribute: &str) {
|
||||
if tree["name"] == element {
|
||||
if let Some(attrs) = tree["attrs"].as_object_mut() {
|
||||
attrs.remove(attribute);
|
||||
}
|
||||
if tree["name"] == element
|
||||
&& let Some(attrs) = tree["attrs"].as_object_mut()
|
||||
{
|
||||
attrs.remove(attribute);
|
||||
}
|
||||
if let Some(children) = tree["children"].as_array_mut() {
|
||||
children
|
||||
|
||||
Reference in new issue
Block a user