public static void removeCardFromCurrentlyOpenCardViewer(String cardID) {
        if (!mostRecentCardViewer.isShowing()) {
            return;
        }
        Card previous;
        for (Card e : mostRecentCardViewer.cards) {
            previous = e;
            if (e.getID().equals(cardID)) {
                mostRecentCardViewer.cards.remove(e);
                mostRecentCardViewer.showCards(previous);
                String x = mostRecentCardViewerLabel.getText();
                if (x.contains(" cards)")) {
                    int value = Integer.parseInt(
                            x.substring(x.lastIndexOf("(") + 1,
                            x.lastIndexOf(" ")));
                    mostRecentCardViewerLabel.setText(
                            x.substring(0, x.lastIndexOf("(") + 1)
                            + (value - 1) + " cards)");
                }
                break;
            }
        }
    }