Merge pull request #14427 from Simonx22/qt/cheats-gecko-download-error-message

DolphinQt: Improve Gecko code download failure message
This commit is contained in:
JMC47
2026-03-12 15:25:41 -04:00
committed by GitHub
4 changed files with 18 additions and 13 deletions

View File

@@ -190,11 +190,10 @@ Java_org_dolphinemu_dolphinemu_features_cheats_model_GeckoCheat_downloadCodes(JN
{
const std::string gametdb_id = GetJString(env, jGameTdbId);
bool success = true;
const std::vector<Gecko::GeckoCode> codes = Gecko::DownloadCodes(gametdb_id, &success);
if (!success)
const auto codes_result = Gecko::DownloadCodes(gametdb_id);
if (!codes_result)
return nullptr;
const std::vector<Gecko::GeckoCode>& codes = *codes_result;
const jobjectArray array =
env->NewObjectArray(static_cast<jsize>(codes.size()), IDCache::GetGeckoCheatClass(), nullptr);