Clippy: Fixed warnings in htmlimageelement.rs (#31800)

* Fixed warnings in htmlimageelement.rs

* making changes for test-tidy to run without errors.
This commit is contained in:
Aarya Khandelwal 2024-03-21 13:30:24 +05:30 committed by GitHub
parent da3288dd00
commit 7cdff9dd06
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 22 additions and 22 deletions

View file

@ -696,10 +696,10 @@ impl VirtualMethods for HTMLIFrameElement {
}
fn parse_plain_attribute(&self, name: &LocalName, value: DOMString) -> AttrValue {
match name {
&local_name!("sandbox") => AttrValue::from_serialized_tokenlist(value.into()),
&local_name!("width") => AttrValue::from_dimension(value.into()),
&local_name!("height") => AttrValue::from_dimension(value.into()),
match *name {
local_name!("sandbox") => AttrValue::from_serialized_tokenlist(value.into()),
local_name!("width") => AttrValue::from_dimension(value.into()),
local_name!("height") => AttrValue::from_dimension(value.into()),
_ => self
.super_type()
.unwrap()
@ -708,7 +708,7 @@ impl VirtualMethods for HTMLIFrameElement {
}
fn bind_to_tree(&self, context: &BindContext) {
if let Some(ref s) = self.super_type() {
if let Some(s) = self.super_type() {
s.bind_to_tree(context);
}