Try to get find cards in same set first#10397
Try to get find cards in same set first#10397clairchiara wants to merge 2 commits intoCard-Forge:masterfrom
Conversation
|
I'd think if the card exists in the set but we've requested an invalid art index or collector number, that's a sign the problem is primarily with the request. In this case, it seems like that deck should be using art index 2. Note how they both have text in the bottom left indicating which deck they're meant for: Art index 1 - CN315 Falling back to the same set upon a failed request does make a kind of sense, but I think it'd make it harder to catch other mistakes like these. |
0b0aa94 to
7232f2a
Compare
|
@Jetz72 |
7232f2a to
1b1128f
Compare
1b1128f to
2efa5dd
Compare
The warning might be more appropriate, then, so we can track down those invalid card requests. If a card request comes with a specific set and collector number or art index, and the card isn't there, then either the request is erroneous or the edition is missing an entry. Either way, picking the next closest card with no warning means some issue gets covered it. |
If card is not found with artIndex and/or collectorNumber, try again to find it in the same set without them. Only then fallback to full database if still not found.
Example: the 40K commander precon "Ruinous Powers" contains
Mountain|40K|3. Although the 40K set has Mountains, it does not have one at artIndex 3. Currently this causes another Mountain to be loaded according to user art preferences, either from LEA or the latest set (eg TMT). A more logical behavior would be to load another Mountain from 40K instead, as these are available.