diff --git a/Mage.Client/src/main/java/mage/client/util/gui/ArrowBuilder.java b/Mage.Client/src/main/java/mage/client/util/gui/ArrowBuilder.java index 3520af3b4c..b471998a53 100644 --- a/Mage.Client/src/main/java/mage/client/util/gui/ArrowBuilder.java +++ b/Mage.Client/src/main/java/mage/client/util/gui/ArrowBuilder.java @@ -112,10 +112,11 @@ public class ArrowBuilder { * Removes all arrows from the screen. */ public void removeAllArrows(UUID gameId) { - if (map.containsKey(gameId)) { - Map> innerMap = map.get(gameId); - JPanel p = getArrowsPanel(gameId); - synchronized (map) { + synchronized (map) { + if (map.containsKey(gameId)) { + Map> innerMap = map.get(gameId); + JPanel p = getArrowsPanel(gameId); + if (p != null && p.getComponentCount() > 0) { p.removeAll(); p.revalidate();