Fix Clippy warning (#285)
This commit is contained in:
parent
ba9c7b523c
commit
9a2c4fba4f
1 changed files with 10 additions and 7 deletions
|
@ -164,13 +164,16 @@ fn desugar_attrs(attrs: Vec<Attr>) -> Vec<Attribute> {
|
||||||
let mut attributes = vec![];
|
let mut attributes = vec![];
|
||||||
for attr in attrs {
|
for attr in attrs {
|
||||||
match attr {
|
match attr {
|
||||||
Attr::Class { name, toggler, .. } => {
|
Attr::Class {
|
||||||
if let Some(toggler) = toggler {
|
name,
|
||||||
classes_toggled.push((name, toggler));
|
toggler: Some(toggler),
|
||||||
} else {
|
..
|
||||||
classes_static.push(name);
|
} => classes_toggled.push((name, toggler)),
|
||||||
}
|
Attr::Class {
|
||||||
}
|
name,
|
||||||
|
toggler: None,
|
||||||
|
..
|
||||||
|
} => classes_static.push(name),
|
||||||
Attr::Id { name, .. } => ids.push(name),
|
Attr::Id { name, .. } => ids.push(name),
|
||||||
Attr::Attribute { attribute } => attributes.push(attribute),
|
Attr::Attribute { attribute } => attributes.push(attribute),
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue