Fix OOB index crash

This commit is contained in:
Danny McGee
2024-04-10 03:16:10 -04:00
parent da086e9573
commit 8a1c616fb1
+4 -2
View File
@@ -150,8 +150,10 @@ fn update_selection(
},
);
if hits.is_empty() && !is_multi {
cmd.remove_resource::<Selection>();
if hits.is_empty() {
if !is_multi {
cmd.remove_resource::<Selection>();
}
continue;
}