[Crash] Fix player events reload when out of bounds (#4321)

This commit is contained in:
Chris Miles authored and GitHub committed 2024-05-24 21:53:47 -04:00
1 parent 3a51f04291
commit 2586527157
1 file changed
+4
+4
View File
@@ -642,6 +642,10 @@ void PlayerEventLogs::ProcessRetentionTruncation()
void PlayerEventLogs::ReloadSettings()
{
for (auto &e: PlayerEventLogSettingsRepository::All(*m_database)) {
if (e.id >= PlayerEvent::MAX || e.id < 0) {
continue;
}
m_settings[e.id] = e;
}
}