Poll active stories in supergroups.

This commit is contained in:
levlam 2024-02-09 15:40:17 +03:00
parent 423688771d
commit 2220d6bd32
2 changed files with 6 additions and 6 deletions

View File

@ -5018,7 +5018,7 @@ canSendStoryResultOk = CanSendStoryResult;
//@description The user must subscribe to Telegram Premium to be able to post stories
canSendStoryResultPremiumNeeded = CanSendStoryResult;
//@description The channel chat must be boosted first by Telegram Premium subscribers to post more stories. Call getChatBoostStatus to get current boost status of the chat
//@description The chat must be boosted first by Telegram Premium subscribers to post more stories. Call getChatBoostStatus to get current boost status of the chat
canSendStoryResultBoostNeeded = CanSendStoryResult;
//@description The limit for the number of active stories exceeded. The user can buy Telegram Premium, delete an active story, or wait for the oldest story to expire
@ -8395,13 +8395,13 @@ readChatList chat_list:ChatList = Ok;
//@only_local Pass true to get only locally available information without sending network requests
getStory story_sender_chat_id:int53 story_id:int32 only_local:Bool = Story;
//@description Returns channel chats in which the current user has the right to post stories. The chats must be rechecked with canSendStory before actually trying to post a story there
//@description Returns supergroup and channel chats in which the current user has the right to post stories. The chats must be rechecked with canSendStory before actually trying to post a story there
getChatsToSendStories = Chats;
//@description Checks whether the current user can send a story on behalf of a chat; requires can_post_stories rights for channel chats @chat_id Chat identifier
//@description Checks whether the current user can send a story on behalf of a chat; requires can_post_stories rights for supergroup and channel chats @chat_id Chat identifier
canSendStory chat_id:int53 = CanSendStoryResult;
//@description Sends a new story to a chat; requires can_post_stories rights for channel chats. Returns a temporary story
//@description Sends a new story to a chat; requires can_post_stories rights for supergroup and channel chats. Returns a temporary story
//@chat_id Identifier of the chat that will post the story
//@content Content of the story
//@areas Clickable rectangle areas to be shown on the story media; pass null if none
@ -8460,7 +8460,7 @@ getChatActiveStories chat_id:int53 = ChatActiveStories;
//-For optimal performance, the number of returned stories is chosen by TDLib and can be smaller than the specified limit
getChatPinnedStories chat_id:int53 from_story_id:int32 limit:int32 = Stories;
//@description Returns the list of all stories posted by the given chat; requires can_edit_stories rights for channel chats.
//@description Returns the list of all stories posted by the given chat; requires can_edit_stories rights for supergroup and channel chats.
//-The stories are returned in a reverse chronological order (i.e., in order of decreasing story_id). For optimal performance, the number of returned stories is chosen by TDLib
//@chat_id Chat identifier
//@from_story_id Identifier of the story starting from which stories must be returned; use 0 to get results from the last story

View File

@ -18157,7 +18157,7 @@ int64 ContactsManager::get_supergroup_id_object(ChannelId channel_id, const char
}
bool ContactsManager::need_poll_channel_active_stories(const Channel *c, ChannelId channel_id) const {
return c != nullptr && !c->is_megagroup && !get_channel_status(c).is_member() &&
return c != nullptr && !get_channel_status(c).is_member() &&
have_input_peer_channel(c, channel_id, AccessRights::Read);
}