mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Remove a pointless level of indentation.
This commit is contained in:
parent
a701397a9d
commit
b96594ea50
1 changed files with 8 additions and 8 deletions
|
@ -65,14 +65,14 @@ fn collect_text(element: &Element, value: &mut DOMString) {
|
|||
let html_script = element.is_htmlscriptelement();
|
||||
if svg_script || html_script {
|
||||
return;
|
||||
} else {
|
||||
for child in NodeCast::from_ref(element).children() {
|
||||
if child.r().is_text() {
|
||||
let characterdata = CharacterDataCast::to_ref(child.r()).unwrap();
|
||||
value.push_str(&characterdata.Data());
|
||||
} else if let Some(element_child) = ElementCast::to_ref(&*child) {
|
||||
collect_text(element_child, value);
|
||||
}
|
||||
}
|
||||
|
||||
for child in NodeCast::from_ref(element).children() {
|
||||
if child.r().is_text() {
|
||||
let characterdata = CharacterDataCast::to_ref(child.r()).unwrap();
|
||||
value.push_str(&characterdata.Data());
|
||||
} else if let Some(element_child) = ElementCast::to_ref(&*child) {
|
||||
collect_text(element_child, value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue