mirror of
https://github.com/servo/servo.git
synced 2025-06-24 09:04:33 +01:00
Pass a non-Option DOMString to after_remove_attr.
This commit is contained in:
parent
58b317837b
commit
fdd17b4139
1 changed files with 3 additions and 3 deletions
|
@ -291,7 +291,7 @@ impl Element {
|
||||||
None => (),
|
None => (),
|
||||||
Some(idx) => {
|
Some(idx) => {
|
||||||
let removed = self.attrs.remove(idx);
|
let removed = self.attrs.remove(idx);
|
||||||
let removed_raw_value = Some(removed.get().Value());
|
let removed_raw_value = removed.get().Value();
|
||||||
|
|
||||||
if namespace == namespace::Null {
|
if namespace == namespace::Null {
|
||||||
self.after_remove_attr(abstract_self, local_name, removed_raw_value);
|
self.after_remove_attr(abstract_self, local_name, removed_raw_value);
|
||||||
|
@ -305,7 +305,7 @@ impl Element {
|
||||||
fn after_remove_attr(&mut self,
|
fn after_remove_attr(&mut self,
|
||||||
abstract_self: &JS<Element>,
|
abstract_self: &JS<Element>,
|
||||||
local_name: DOMString,
|
local_name: DOMString,
|
||||||
old_value: Option<DOMString>) {
|
old_value: DOMString) {
|
||||||
match local_name.as_slice() {
|
match local_name.as_slice() {
|
||||||
"style" => {
|
"style" => {
|
||||||
self.style_attribute = None
|
self.style_attribute = None
|
||||||
|
@ -317,7 +317,7 @@ impl Element {
|
||||||
// "borrowed value does not live long enough"
|
// "borrowed value does not live long enough"
|
||||||
let mut doc = self.node.owner_doc();
|
let mut doc = self.node.owner_doc();
|
||||||
let doc = doc.get_mut();
|
let doc = doc.get_mut();
|
||||||
doc.update_idmap(abstract_self, None, old_value);
|
doc.update_idmap(abstract_self, None, Some(old_value));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
_ => ()
|
_ => ()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue