forked from External/mage
Fixed NPE errors for some cards (#5471)
This commit is contained in:
parent
cbfdcd12c1
commit
8c7df840f3
21 changed files with 136 additions and 186 deletions
|
|
@ -186,7 +186,9 @@ public class Library implements Serializable {
|
|||
Map<String, Card> cards = new HashMap<>();
|
||||
for (UUID cardId : library) {
|
||||
Card card = game.getCard(cardId);
|
||||
cards.putIfAbsent(card.getName(), card);
|
||||
if (card != null) {
|
||||
cards.putIfAbsent(card.getName(), card);
|
||||
}
|
||||
}
|
||||
return cards.values();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue