Fixe some clippy warnings (#32131)

This commit is contained in:
komuhangi 2024-04-29 15:22:30 +03:00 committed by GitHub
parent d490fdf83c
commit 5a4c81f841
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 32 additions and 36 deletions

View file

@ -484,12 +484,11 @@ impl CustomElementRegistryMethods for CustomElementRegistry {
if form_associated {
let _ac = JSAutoRealm::new(*cx, proto_object.get());
unsafe {
match self.add_form_associated_callbacks(proto_object.handle(), &mut callbacks) {
Err(error) => {
self.element_definition_is_running.set(false);
return Err(error);
},
Ok(()) => {},
if let Err(error) =
self.add_form_associated_callbacks(proto_object.handle(), &mut callbacks)
{
self.element_definition_is_running.set(false);
return Err(error);
}
}
}
@ -673,6 +672,7 @@ pub struct CustomElementDefinition {
}
impl CustomElementDefinition {
#[allow(clippy::too_many_arguments)]
fn new(
name: LocalName,
local_name: LocalName,