We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 2df9f5d + 559172d commit 42f2124Copy full SHA for 42f2124
crates/bevy_ui/src/render/render_pass.rs
@@ -66,10 +66,11 @@ impl Node for UiPassNode {
66
world: &World,
67
) -> Result<(), NodeRunError> {
68
let view_entity = graph.get_input_entity(Self::IN_VIEW)?;
69
- let (transparent_phase, target) = self
70
- .query
71
- .get_manual(world, view_entity)
72
- .expect("view entity should exist");
+ // If there is no view entity, do not try to process the render phase for the view
+ let (transparent_phase, target) = match self.query.get_manual(world, view_entity) {
+ Ok(it) => it,
+ _ => return Ok(()),
73
+ };
74
let pass_descriptor = RenderPassDescriptor {
75
label: Some("ui_pass"),
76
color_attachments: &[RenderPassColorAttachment {
0 commit comments