Avoid trying to generate a move option for cards that don't have a valid destination

This commit is contained in:
Jetz
2025-08-15 23:51:19 -04:00
parent 0e2c95afed
commit 7c982498dd

View File

@@ -1793,7 +1793,7 @@ public class FDeckEditor extends TabPageScreen<FDeckEditor> {
DeckSection destination = DeckSection.matchingSection(card);
final DeckSectionPage destinationPage = parentScreen.getPageForSection(destination);
if (!needsCommander() && !canOnlyBePartnerCommander(card)) {
if (!needsCommander() && !canOnlyBePartnerCommander(card) && destinationPage != null) {
addMoveCardMenuItem(menu, card, this, destinationPage);
if (canSideboard(card) && destination != DeckSection.Sideboard) {
addMoveCardMenuItem(menu, card, this, parentScreen.getSideboardPage());