Skip to content

Commit

Permalink
Fix clippy lints
Browse files Browse the repository at this point in the history
  • Loading branch information
kennethloeffler committed Oct 30, 2024
1 parent 0877ca7 commit 555ccfc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
6 changes: 1 addition & 5 deletions rbx_dom_weak/src/dom.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,11 +123,7 @@ impl WeakDom {
parent,
name: builder.name,
class: builder.class,
properties: builder
.properties
.into_iter()
.map(|(k, v)| (k, v))
.collect(),
properties: builder.properties.into_iter().collect(),
},
);

Expand Down
2 changes: 1 addition & 1 deletion rbx_dom_weak/src/instance.rs
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ impl InstanceBuilder {
/// Check if the `InstanceBuilder` already has a property with the given key.
pub fn has_property<K: Into<Ustr>>(&self, key: K) -> bool {
let key = key.into();
self.properties.iter().find(|(k, _)| *k == key).is_some()
self.properties.iter().any(|(k, _)| *k == key)
}

/// Add multiple properties to the `InstanceBuilder` at once.
Expand Down

0 comments on commit 555ccfc

Please sign in to comment.