Skip to content

Commit 56c9dd4

Browse files
committed
cleanup
1 parent 3f8a762 commit 56c9dd4

File tree

1 file changed

+2
-6
lines changed
  • crates/bevy_ui/src/render

1 file changed

+2
-6
lines changed

crates/bevy_ui/src/render/mod.rs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -195,13 +195,9 @@ pub fn extract_uinodes(
195195
}
196196

197197
let (image, atlas_size, rect_min) = match image {
198-
UiImage::Image(handle) => {
199-
let handle = handle.clone_weak();
200-
(handle, None, Vec2::ZERO)
201-
}
198+
UiImage::Image(handle) => (handle.clone_weak(), None, Vec2::ZERO),
202199
UiImage::TextureAtlas { handle, index } => {
203-
let handle = handle.clone_weak();
204-
if let Some(atlas) = texture_atlases.get(&handle) {
200+
if let Some(atlas) = texture_atlases.get(handle) {
205201
let rect = atlas.textures.get(*index).copied().unwrap_or_else(|| {
206202
panic!("TextureAtlas {:?} as no texture at index {}", atlas, index)
207203
});

0 commit comments

Comments
 (0)