mirror of
https://github.com/rojo-rbx/rojo.git
synced 2026-10-23 22:11:38 +00:00
Refactor code for improved clarity and maintainability
- Added `#[allow(clippy::too_many_arguments)]` annotations in `change_processor.rs` and `matching.rs` to suppress warnings for functions with multiple parameters. - Updated `serve_session.rs` to include `clippy::type_complexity` in the `#[allow(dead_code)]` annotation for better code quality. - Simplified array initialization in `file_names.rs` for consistency. - Enhanced texture filtering logic in `matching_fixtures.rs` by replacing `map_or` with `is_some_and` for improved readability. These changes contribute to a cleaner codebase and address static analysis warnings, ensuring better maintainability.
This commit is contained in:
parent
dea60eb4cf
commit
df22500102
7 changed files with 24 additions and 24 deletions
|
|
@ -134,7 +134,7 @@ fn get_texture_children(dom: &WeakDom, parent: Ref) -> Vec<Ref> {
|
|||
.iter()
|
||||
.filter(|&&r| {
|
||||
dom.get_by_ref(r)
|
||||
.map_or(false, |i| i.class.as_str() == "Texture")
|
||||
.is_some_and(|i| i.class.as_str() == "Texture")
|
||||
})
|
||||
.copied()
|
||||
.collect()
|
||||
|
|
@ -293,7 +293,7 @@ fn forward_matching_ufowave_textures() {
|
|||
.iter()
|
||||
.filter(|&&r| {
|
||||
tree.get_instance(r)
|
||||
.map_or(false, |i| i.class_name().as_str() == "Texture")
|
||||
.is_some_and(|i| i.class_name().as_str() == "Texture")
|
||||
})
|
||||
.copied()
|
||||
.collect();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue