Merge pull request #275 from BarryYan/master

fix: add ns param for removeAttribute
This commit is contained in:
Jonathan Kelley authored and GitHub committed 2022-02-25 11:50:21 -05:00
commit d8718efed6
4 files changed
+21 -11

No files matched your search

+10 -2
View File
@@ -107,6 +107,7 @@ pub enum DomEdit<'bump> {
RemoveAttribute {
root: u64,
name: &'static str,
ns: Option<&'bump str>,
},
}
@@ -218,8 +219,15 @@ impl<'a> Mutations<'a> {
}
pub(crate) fn remove_attribute(&mut self, attribute: &Attribute, root: u64) {
let name = attribute.name;
self.edits.push(RemoveAttribute { name, root });
let Attribute {
name, namespace, ..
} = attribute;
self.edits.push(RemoveAttribute {
name,
ns: *namespace,
root,
});
}
pub(crate) fn mark_dirty_scope(&mut self, scope: ScopeId) {