From bc3b798d04072db04805b38897f9fa5f680ca7c7 Mon Sep 17 00:00:00 2001 From: AlexeyZavar Date: Fri, 24 Apr 2026 20:35:04 +0300 Subject: [PATCH] chore: disable username resolving tgdb requires subscription usinfobot requires `/start` --- README-RU.md | 2 +- README.md | 2 +- Telegram/SourceFiles/ayu/utils/telegram_helpers.cpp | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/README-RU.md b/README-RU.md index 85745d095b..d34d232d93 100644 --- a/README-RU.md +++ b/README-RU.md @@ -159,4 +159,4 @@ Flatpak: https://github.com/0FL01/AyuGramDesktop-flatpak ### Боты -- [TelegramDB](https://t.me/tgdatabase) для получения юзернейма по ID +- [TelegramDB](https://t.me/tgdatabase) для получения юзернейма по ID (до закрытия бесплатной версии 2 апреля 2026) diff --git a/README.md b/README.md index 414554d79d..b2bc688dec 100644 --- a/README.md +++ b/README.md @@ -161,4 +161,4 @@ Enjoy using **AyuGram**? Consider sending us a tip! ### Bots -- [TelegramDB](https://t.me/tgdatabase) for username lookup by ID +- [TelegramDB](https://t.me/tgdatabase) for username lookup by ID (until closing free inline mode at 2 April 2026) diff --git a/Telegram/SourceFiles/ayu/utils/telegram_helpers.cpp b/Telegram/SourceFiles/ayu/utils/telegram_helpers.cpp index 3a6690880b..032fec395e 100644 --- a/Telegram/SourceFiles/ayu/utils/telegram_helpers.cpp +++ b/Telegram/SourceFiles/ayu/utils/telegram_helpers.cpp @@ -877,7 +877,8 @@ void searchPeerInner(const QString &peerId, Main::Session *session, const Userna } void searchPeer(const QString &peerId, Main::Session *session, const UsernameResolverCallback &callback) { - if (!session) { + callback(QString(), nullptr); + /*if (!session) { callback(QString(), nullptr); return; } @@ -893,7 +894,7 @@ void searchPeer(const QString &peerId, Main::Session *session, const UsernameRes { searchPeerInner(peerId, session, callback); }); - } + }*/ } void searchUserById(ID userId, Main::Session *session, const UsernameResolverCallback &callback) {