From 013b58f6f6f7d0886fdedc79dd9c18c9d85d1b94 Mon Sep 17 00:00:00 2001
From: 23rd <23rd@vivaldi.net>
Date: Fri, 15 Nov 2024 20:04:33 +0300
Subject: [PATCH] Fixed display of forums in share box with applied chats
 filter.

---
 Telegram/SourceFiles/boxes/share_box.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Telegram/SourceFiles/boxes/share_box.cpp b/Telegram/SourceFiles/boxes/share_box.cpp
index a2c1db10a..eed3a2e04 100644
--- a/Telegram/SourceFiles/boxes/share_box.cpp
+++ b/Telegram/SourceFiles/boxes/share_box.cpp
@@ -1388,7 +1388,8 @@ void ShareBox::Inner::applyChatFilter(FilterId id) {
 		const auto addList = [&](not_null<Dialogs::IndexedList*> list) {
 			for (const auto &row : list->all()) {
 				if (const auto history = row->history()) {
-					if (_descriptor.filterCallback(history)) {
+					if (history->asForum()
+							|| _descriptor.filterCallback(history)) {
 						_customChatsIndexed->addToEnd(history);
 					}
 				}