Skip to content

Commit

Permalink
Apply clippy::question_mark suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
pablosichert committed Apr 24, 2024
1 parent 9440e4e commit 1241704
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions crates/webidl/src/generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -701,9 +701,7 @@ impl DictionaryField {
&required_doc_string(options, features),
);

let Some(return_ty) = return_ty else {
return None;
};
let return_ty = return_ty.as_ref()?;

quote! {
#unstable_attr
Expand Down Expand Up @@ -731,9 +729,7 @@ impl DictionaryField {

let unstable_attr = maybe_unstable_attr(*unstable);

let Some(return_ty) = return_ty else {
return None;
};
let return_ty = return_ty.as_ref()?;
let shim_name = self.shim_name();

quote! {
Expand Down

0 comments on commit 1241704

Please sign in to comment.