summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinWX/ISOFile.cpp
diff options
context:
space:
mode:
authorLéo Lam <leolino.lam@gmail.com>2017-05-07 18:48:43 +0200
committerGitHub <noreply@github.com>2017-05-07 18:48:43 +0200
commiteff8c1eb488d9c03b30c9258a20fa425e0abd389 (patch)
treee153531d338a7581eeda6a6ce4e7ad0dd083ddd6 /Source/Core/DolphinWX/ISOFile.cpp
parent71400745ccdf6fcff31815f803d4160a92b77d89 (diff)
parent9b8089bb70d787da4a3b083b17c434df17d90805 (diff)
Merge pull request #5383 from JosJuice/getwiifspath-condition
ISOFile/GameFile: Correct GetWiiFSPath condition
Diffstat (limited to 'Source/Core/DolphinWX/ISOFile.cpp')
-rw-r--r--Source/Core/DolphinWX/ISOFile.cpp20
1 files changed, 8 insertions, 12 deletions
diff --git a/Source/Core/DolphinWX/ISOFile.cpp b/Source/Core/DolphinWX/ISOFile.cpp
index ac4c901894..9e115a988d 100644
--- a/Source/Core/DolphinWX/ISOFile.cpp
+++ b/Source/Core/DolphinWX/ISOFile.cpp
@@ -361,20 +361,16 @@ std::vector<DiscIO::Language> GameListItem::GetLanguages() const
const std::string GameListItem::GetWiiFSPath() const
{
- std::string ret;
+ if (m_Platform != DiscIO::Platform::WII_DISC && m_Platform != DiscIO::Platform::WII_WAD)
+ return "";
- if (m_Platform != DiscIO::Platform::GAMECUBE_DISC)
- {
- const std::string path = Common::GetTitleDataPath(m_title_id, Common::FROM_CONFIGURED_ROOT);
+ const std::string path = Common::GetTitleDataPath(m_title_id, Common::FROM_CONFIGURED_ROOT);
- if (!File::Exists(path))
- File::CreateFullPath(path);
+ if (!File::Exists(path))
+ File::CreateFullPath(path);
- if (path[0] == '.')
- ret = WxStrToStr(wxGetCwd()) + path.substr(strlen(ROOT_DIR));
- else
- ret = path;
- }
+ if (path[0] == '.')
+ return WxStrToStr(wxGetCwd()) + path.substr(strlen(ROOT_DIR));
- return ret;
+ return path;
}