diff options
| author | Chris Bessent <lost.dragonist@gmail.com> | 2021-11-22 17:02:07 -0700 |
|---|---|---|
| committer | Chris Bessent <lost.dragonist@gmail.com> | 2021-11-22 21:05:49 -0700 |
| commit | a1e953f40936c9e52292fd06cb9b80fd66bf5e43 (patch) | |
| tree | 0edc74add0b004a86e404f51691ad10217f980d8 /src/nexusinterface.cpp | |
| parent | b1db3019f4700021479e811029b11f3f824a244f (diff) | |
Don't add invalid games to the "visit Nexus" list
Diffstat (limited to 'src/nexusinterface.cpp')
| -rw-r--r-- | src/nexusinterface.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/nexusinterface.cpp b/src/nexusinterface.cpp index 1364d7e1..2e4496e1 100644 --- a/src/nexusinterface.cpp +++ b/src/nexusinterface.cpp @@ -371,7 +371,13 @@ QString NexusInterface::getGameURL(QString gameName) const { IPluginGame *game = getGame(gameName); if (game != nullptr) { - return "https://www.nexusmods.com/" + game->gameNexusName().toLower(); + QString gameNexusName = game->gameNexusName().toLower(); + if (gameNexusName.isEmpty()) { + return ""; + } + else { + return "https://www.nexusmods.com/" + gameNexusName; + } } else { log::error("getGameURL can't find plugin for {}", gameName); return ""; |
