mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-30 22:16:14 +00:00
Show only one placeholder for premium reactions.
This commit is contained in:
@@ -323,6 +323,15 @@ rpl::producer<bool> CanManageGroupCallValue(not_null<PeerData*> peer) {
|
||||
return rpl::single(false);
|
||||
}
|
||||
|
||||
rpl::producer<bool> AmPremiumValue(not_null<Main::Session*> session) {
|
||||
return session->user()->flagsValue(
|
||||
) | rpl::filter([=](UserData::Flags::Change change) {
|
||||
return (change.diff & UserDataFlag::Premium);
|
||||
}) | rpl::map([=] {
|
||||
return session->user()->isPremium();
|
||||
});
|
||||
}
|
||||
|
||||
TimeId SortByOnlineValue(not_null<UserData*> user, TimeId now) {
|
||||
if (user->isServiceUser() || user->isBot()) {
|
||||
return -1;
|
||||
|
Reference in New Issue
Block a user