AchievementManager: Remove unnecessary .get()

Same behavior, less code.
This commit is contained in:
Lioncash 2024-01-31 22:01:43 -05:00
parent 161efff6c9
commit 394418b415
1 changed files with 3 additions and 6 deletions

View File

@ -178,16 +178,13 @@ void AchievementManager::HashGame(const DiscIO::Volume* volume, const ResponseCa
return;
}
// Need to SetDisabled outside a lock because it uses m_lock internally.
bool disable = false;
bool disable = true;
{
std::lock_guard lg{m_lock};
if (m_loading_volume.get() != nullptr)
{
disable = true;
}
else
if (!m_loading_volume)
{
m_loading_volume = DiscIO::CreateVolume(volume->GetBlobReader().CopyReader());
disable = false;
}
}
if (disable)