Removed JS::root Fixes #8251

This commit is contained in:
nxnfufunezn 2015-10-31 17:41:00 +05:30
parent 521a87180a
commit d8ef3809a6
25 changed files with 98 additions and 126 deletions

View file

@ -42,7 +42,7 @@ impl NamedNodeMapMethods for NamedNodeMap {
// https://dom.spec.whatwg.org/#dom-namednodemap-item
fn Item(&self, index: u32) -> Option<Root<Attr>> {
self.owner.attrs().get(index as usize).map(JS::root)
self.owner.attrs().get(index as usize).map(|js| Root::from_ref(&**js))
}
// https://dom.spec.whatwg.org/#dom-namednodemap-getnameditem
@ -87,7 +87,7 @@ impl NamedNodeMapMethods for NamedNodeMap {
// https://heycam.github.io/webidl/#dfn-supported-property-names
fn SupportedPropertyNames(&self) -> Vec<DOMString> {
self.owner.attrs().iter().map(JS::root).map(|attr| {
self.owner.attrs().iter().map(|attr| {
(**attr.name()).to_owned()
}).collect()
}