Skip to content

Commit

Permalink
clippy tutor
Browse files Browse the repository at this point in the history
  • Loading branch information
shnewto committed Mar 4, 2024
1 parent 26dee55 commit 4d2cb60
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/rapier2d_colliders.rs
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ pub fn controls_text_spawn(mut commands: Commands, game_assets: Res<GameAsset>)
"}
.into();

if game_assets.image_handles.get("car_handle").is_some() {
if game_assets.image_handles.contains_key("car_handle") {
let car_controls: String = indoc! {"
a d (move car)
1 (reset car transform to initial)
Expand Down
2 changes: 1 addition & 1 deletion examples/xpbd_2d_colliders.rs
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ pub fn controls_text_spawn(mut commands: Commands, game_assets: Res<GameAsset>)
"}
.into();

if game_assets.image_handles.get("car_handle").is_some() {
if game_assets.image_handles.contains_key("car_handle") {
let car_controls: String = indoc! {"
a d (move car)
1 (reset car transform to initial)
Expand Down

0 comments on commit 4d2cb60

Please sign in to comment.