Merge pull request #8074 from Qyriad/fixes/set-user-dir-properly

UICommon: Properly set user dir if ./user is a file (not a directory)
This commit is contained in:
Connor McLaughlin 2019-05-04 16:15:00 +10:00 committed by GitHub
commit 184f334158
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -253,7 +253,7 @@ void SetUserDirectory(const std::string& custom_path)
user_path += DIR_SEP;
#else
if (File::Exists(ROOT_DIR DIR_SEP USERDATA_DIR))
if (File::IsDirectory(ROOT_DIR DIR_SEP USERDATA_DIR))
{
user_path = ROOT_DIR DIR_SEP USERDATA_DIR DIR_SEP;
}