From 260b9cdf9edcd67fd3b1a21e3625bfc03eec01f6 Mon Sep 17 00:00:00 2001 From: levlam Date: Fri, 29 Mar 2024 11:28:48 +0300 Subject: [PATCH] Add td_api::premiumFeatureBusiness. --- td/generate/scheme/td_api.tl | 3 +++ td/telegram/Premium.cpp | 5 +++++ 2 files changed, 8 insertions(+) diff --git a/td/generate/scheme/td_api.tl b/td/generate/scheme/td_api.tl index 4047a1894..78c960994 100644 --- a/td/generate/scheme/td_api.tl +++ b/td/generate/scheme/td_api.tl @@ -4992,6 +4992,9 @@ premiumFeatureMessagePrivacy = PremiumFeature; //@description The ability to view last seen and read times of other users even they can't view last seen or read time for the current user premiumFeatureLastSeenTimes = PremiumFeature; +//@description The ability to use Business features +premiumFeatureBusiness = PremiumFeature; + //@class BusinessFeature @description Describes a feature available to Business user accounts diff --git a/td/telegram/Premium.cpp b/td/telegram/Premium.cpp index 11213e0fd..11ab4956c 100644 --- a/td/telegram/Premium.cpp +++ b/td/telegram/Premium.cpp @@ -108,6 +108,9 @@ static td_api::object_ptr get_premium_feature_object(Sli if (premium_feature == "last_seen") { return td_api::make_object(); } + if (premium_feature == "business") { + return td_api::make_object(); + } if (G()->is_test_dc()) { LOG(ERROR) << "Receive unsupported premium feature " << premium_feature; } @@ -811,6 +814,8 @@ static string get_premium_source(const td_api::PremiumFeature *feature) { return "message_privacy"; case td_api::premiumFeatureLastSeenTimes::ID: return "last_seen"; + case td_api::premiumFeatureBusiness::ID: + return "business"; default: UNREACHABLE(); }