diff options
author | metamuffin <metamuffin@disroot.org> | 2025-01-27 15:26:00 +0100 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2025-01-27 15:26:00 +0100 |
commit | c121d94f0b27bc04ffbdca55cd0939c1401d5a2e (patch) | |
tree | 67ac9da1f994c24b9a3e8e8d2adc2e334d2e34a5 /world/src/physics.rs | |
parent | 6b5c44d58e6c6d3df360396a0897290fc603699b (diff) | |
download | weareserver-c121d94f0b27bc04ffbdca55cd0939c1401d5a2e.tar weareserver-c121d94f0b27bc04ffbdca55cd0939c1401d5a2e.tar.bz2 weareserver-c121d94f0b27bc04ffbdca55cd0939c1401d5a2e.tar.zst |
clippy: fixes and ignores
Diffstat (limited to 'world/src/physics.rs')
-rw-r--r-- | world/src/physics.rs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/world/src/physics.rs b/world/src/physics.rs index 37201af..84f1095 100644 --- a/world/src/physics.rs +++ b/world/src/physics.rs @@ -34,8 +34,7 @@ pub fn import_physics( ) -> Result<()> { if let Some(physics) = node .extensions() - .map(|e| e.get("KHR_physics_rigid_bodies")) - .flatten() + .and_then(|e| e.get("KHR_physics_rigid_bodies")) { info!("--- COLLISION ---"); if let Some(collider) = physics.get("collider") { @@ -43,8 +42,7 @@ pub fn import_physics( if geometry.get("convexHull") == Some(&Value::Bool(true)) { let node = geometry .get("node") - .map(|n| n.as_u64()) - .flatten() + .and_then(|n| n.as_u64()) .ok_or(anyhow!("convexHull node missing"))?; let node = gltf .nodes() |