mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 06:26:18 +00:00
Correctly apply photos from "min" users.
This commit is contained in:
@@ -36,6 +36,7 @@ enum class UserDataFlag {
|
||||
PhoneCallsPrivate = (1 << 9),
|
||||
Support = (1 << 10),
|
||||
CanPinMessages = (1 << 11),
|
||||
DiscardMinPhoto = (1 << 12),
|
||||
};
|
||||
inline constexpr bool is_flag_type(UserDataFlag) { return true; };
|
||||
using UserDataFlags = base::flags<UserDataFlag>;
|
||||
@@ -108,6 +109,9 @@ public:
|
||||
// Duplicated in Data::CanWriteValue().
|
||||
return !isInaccessible() && !isRepliesChat();
|
||||
}
|
||||
[[nodiscard]] bool applyMinPhoto() const {
|
||||
return !(flags() & UserDataFlag::DiscardMinPhoto);
|
||||
}
|
||||
|
||||
[[nodiscard]] bool canShareThisContact() const;
|
||||
[[nodiscard]] bool canAddContact() const {
|
||||
|
Reference in New Issue
Block a user