Fix Crash with "c:" in deck editor

This commit is contained in:
ZeldaZach 2025-01-31 23:11:55 -05:00
parent 82bc2d154e
commit 47efc7ee28
No known key found for this signature in database

View file

@ -281,7 +281,7 @@ static void setupParserRules()
for (const auto &i : sv) {
parts += std::any_cast<char>(i);
}
const bool identity = !sv.tokens[0].empty() && sv.tokens[0][0] != 'i';
const bool identity = sv.tokens[0].empty() || sv.tokens[0][0] != 'i';
if (sv.tokens[1][0] == ':') {
return [=](const CardData &x) {
QString match = identity ? x->getColors() : x->getProperty("coloridentity");