[Friends] Correctly store cache

This commit is contained in:
momo5502 2017-02-19 10:44:45 +01:00
parent 760debe648
commit 81f0116071

View File

@ -437,6 +437,9 @@ namespace Components
{ {
std::lock_guard<std::recursive_mutex> _(Friends::Mutex); std::lock_guard<std::recursive_mutex> _(Friends::Mutex);
// Only store our cache if we are logged in, otherwise it might be invalid
if (!Steam::Proxy::SteamUser_ || !Steam::Proxy::SteamUser_->LoggedOn()) return;
Proto::Friends::List list; Proto::Friends::List list;
for(auto entry : Friends::FriendsList) for(auto entry : Friends::FriendsList)
{ {