AchievementManager: Return by reference from GetLock()

This makes the API a little nicer to use, since you don't need to do
a mandatory dereference when passing the lock into any kind of scope
guard.
This commit is contained in:
Lioncash committed 2023-12-11 13:51:50 -05:00
1 parent 3c7fa0738c
commit d90537cc18
7 files changed
+9 -9

No files matched your search

+1 -1
View File
@@ -330,7 +330,7 @@ void OnScreenUI::DrawDebugText()
#ifdef USE_RETRO_ACHIEVEMENTS
void OnScreenUI::DrawChallenges()
{
std::lock_guard lg{*AchievementManager::GetInstance().GetLock()};
std::lock_guard lg{AchievementManager::GetInstance().GetLock()};
const auto& challenge_icons = AchievementManager::GetInstance().GetChallengeIcons();
if (challenge_icons.empty())
return;