summaryrefslogtreecommitdiff
path: root/Source/Core/UICommon/GameFile.cpp
diff options
context:
space:
mode:
authorLéo Lam <leo@innovatetechnologi.es>2019-05-01 17:34:01 +0200
committerGitHub <noreply@github.com>2019-05-01 17:34:01 +0200
commitef88dd73b32b4de7b3ea509957a1f315662c0d0f (patch)
tree5d115ecba038ed55859cbf0a3a6711f16d4a840c /Source/Core/UICommon/GameFile.cpp
parent3f39aafcbf67ce49c456bc0924cdff77b717a151 (diff)
parent3bef561e5d85a9ea99faa6c1d5d91011607e8c21 (diff)
Merge pull request #8014 from JosJuice/getuniqueidentifier-language-independent
Make GameFile::GetUniqueIdentifier independent of language setting
Diffstat (limited to 'Source/Core/UICommon/GameFile.cpp')
-rw-r--r--Source/Core/UICommon/GameFile.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/Source/Core/UICommon/GameFile.cpp b/Source/Core/UICommon/GameFile.cpp
index b963450cc7..254d19bdf7 100644
--- a/Source/Core/UICommon/GameFile.cpp
+++ b/Source/Core/UICommon/GameFile.cpp
@@ -468,7 +468,12 @@ std::string GameFile::GetUniqueIdentifier() const
if (GetRevision() != 0)
info.push_back("Revision " + std::to_string(GetRevision()));
- const std::string& name = GetName();
+ std::string name = GetLongName(DiscIO::Language::English);
+ if (name.empty())
+ {
+ // Use the file name as a fallback. Not necessarily consistent, but it's the best we have
+ name = m_file_name;
+ }
int disc_number = GetDiscNumber() + 1;