From 9e6a1f3234d338640e0c01f4f9e746e7ed8a64c5 Mon Sep 17 00:00:00 2001 From: Nathan Adams Date: Wed, 15 Mar 2023 09:15:04 +0100 Subject: [PATCH] core: Slightly neater way to get root_mc in context_menu.rs --- core/src/context_menu.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/core/src/context_menu.rs b/core/src/context_menu.rs index 3d0712c6b..5c0d40ae9 100644 --- a/core/src/context_menu.rs +++ b/core/src/context_menu.rs @@ -34,9 +34,7 @@ impl<'gc> ContextMenuState<'gc> { &self.callbacks[index] } pub fn build_builtin_items(&mut self, item_flags: BuiltInItemFlags, stage: Stage<'gc>) { - let root_mc = if let Some(root_clip) = stage.root_clip().and_then(|c| c.as_movie_clip()) { - root_clip - } else { + let Some(root_mc) = stage.root_clip().and_then(|c| c.as_movie_clip()) else { return; }; if item_flags.play {