Don't apply private userpic 'min' updates.

This commit is contained in:
John Preston 2021-03-16 18:15:19 +04:00
parent 61d0d240aa
commit 056cab6268

View file

@ -488,10 +488,12 @@ not_null<UserData*> Session::processUser(const MTPUser &data) {
: result->nameOrPhone;
result->setName(fname, lname, pname, uname);
if (const auto photo = data.vphoto()) {
result->setPhoto(*photo);
} else {
result->setPhoto(MTP_userProfilePhotoEmpty());
if (!minimal || data.is_apply_min_photo()) {
if (const auto photo = data.vphoto()) {
result->setPhoto(*photo);
} else {
result->setPhoto(MTP_userProfilePhotoEmpty());
}
}
if (const auto accessHash = data.vaccess_hash()) {
result->setAccessHash(accessHash->v);