mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 20:28:00 +00:00
FIX cardDb bug for lazy card loading when issuing a request with a non-existing set code.
Code FIX + Test
This commit is contained in:
@@ -249,6 +249,8 @@ public final class CardDb implements ICardDatabase, IDeckGenPool {
|
||||
}
|
||||
} else {
|
||||
CardEdition e = editions.get(setCode);
|
||||
if (e == null)
|
||||
return; // wrong set code - nothing we can do here!
|
||||
List<CardInSet> cardsInSet = e.getCardInSet(cardName); // empty collection if not present
|
||||
for (CardInSet cis : cardsInSet) {
|
||||
addSetCard(e, cis, cr);
|
||||
|
||||
Reference in New Issue
Block a user