diff --git a/example/web/tdweb/src/worker.js b/example/web/tdweb/src/worker.js index 6f7dcfed5..3145d90e8 100644 --- a/example/web/tdweb/src/worker.js +++ b/example/web/tdweb/src/worker.js @@ -409,7 +409,7 @@ class TdClient { name: 'language_pack_database_path' value: { '@type': 'optionValueString', - value: this.tdfs.dbFileSystem.root + '/language' + value: this.tdfs.dbFileSystem.root + '/language' } }); diff --git a/td/mtproto/CryptoStorer.h b/td/mtproto/CryptoStorer.h index 355fc7ca9..1636bcb01 100644 --- a/td/mtproto/CryptoStorer.h +++ b/td/mtproto/CryptoStorer.h @@ -15,6 +15,7 @@ #include "td/utils/logging.h" #include "td/utils/Slice.h" +#include "td/utils/StorerBase.h" #include "td/utils/Time.h" namespace td { diff --git a/td/mtproto/DhHandshake.cpp b/td/mtproto/DhHandshake.cpp index f9f7240b8..69a5015b3 100644 --- a/td/mtproto/DhHandshake.cpp +++ b/td/mtproto/DhHandshake.cpp @@ -9,12 +9,9 @@ #include "td/utils/as.h" #include "td/utils/crypto.h" #include "td/utils/logging.h" -#include "td/utils/misc.h" -#include "td/utils/Random.h" #include "td/utils/Slice.h" #include "td/utils/Status.h" - -#include +#include "td/utils/UInt.h" namespace td { diff --git a/td/mtproto/Handshake.h b/td/mtproto/Handshake.h index 42d79c8a0..7ed919067 100644 --- a/td/mtproto/Handshake.h +++ b/td/mtproto/Handshake.h @@ -13,12 +13,11 @@ #include "td/utils/buffer.h" #include "td/utils/Slice.h" #include "td/utils/Status.h" +#include "td/utils/StorerBase.h" #include "td/utils/UInt.h" namespace td { -class Storer; - namespace mtproto { class AuthKeyHandshakeContext { diff --git a/td/mtproto/HandshakeConnection.h b/td/mtproto/HandshakeConnection.h index f9e9f44e8..e106b6dfe 100644 --- a/td/mtproto/HandshakeConnection.h +++ b/td/mtproto/HandshakeConnection.h @@ -19,6 +19,7 @@ #include "td/utils/logging.h" #include "td/utils/port/detail/PollableFd.h" #include "td/utils/Status.h" +#include "td/utils/StorerBase.h" namespace td { namespace mtproto { diff --git a/td/mtproto/PacketStorer.h b/td/mtproto/PacketStorer.h index f0da60f61..7ad514824 100644 --- a/td/mtproto/PacketStorer.h +++ b/td/mtproto/PacketStorer.h @@ -6,7 +6,7 @@ // #pragma once -#include "td/utils/Storer.h" +#include "td/utils/StorerBase.h" #include "td/utils/tl_storers.h" #include diff --git a/td/mtproto/RawConnection.h b/td/mtproto/RawConnection.h index 2c6987e04..34d1513d2 100644 --- a/td/mtproto/RawConnection.h +++ b/td/mtproto/RawConnection.h @@ -16,20 +16,16 @@ #include "td/utils/port/detail/PollableFd.h" #include "td/utils/port/SocketFd.h" #include "td/utils/Status.h" +#include "td/utils/StorerBase.h" #include "td/telegram/StateManager.h" #include namespace td { -class Storer; namespace mtproto { -class AuthKey; -} // namespace mtproto -} // namespace td -namespace td { -namespace mtproto { +class AuthKey; class RawConnection { public: diff --git a/td/mtproto/SessionConnection.h b/td/mtproto/SessionConnection.h index 77f7b62e3..635c2fa54 100644 --- a/td/mtproto/SessionConnection.h +++ b/td/mtproto/SessionConnection.h @@ -16,6 +16,7 @@ #include "td/utils/port/detail/PollableFd.h" #include "td/utils/Slice.h" #include "td/utils/Status.h" +#include "td/utils/StorerBase.h" #include "td/utils/StringBuilder.h" #include "td/utils/tl_parsers.h" diff --git a/td/mtproto/Transport.h b/td/mtproto/Transport.h index f7479860c..c393daaf0 100644 --- a/td/mtproto/Transport.h +++ b/td/mtproto/Transport.h @@ -7,12 +7,12 @@ #pragma once #include "td/mtproto/PacketInfo.h" -#include "td/mtproto/utils.h" #include "td/utils/common.h" #include "td/utils/logging.h" #include "td/utils/Slice.h" #include "td/utils/Status.h" +#include "td/utils/StorerBase.h" #include "td/utils/UInt.h" #include diff --git a/td/mtproto/utils.h b/td/mtproto/utils.h index a315f63ac..34903b365 100644 --- a/td/mtproto/utils.h +++ b/td/mtproto/utils.h @@ -12,6 +12,7 @@ #include "td/utils/Slice.h" #include "td/utils/Status.h" #include "td/utils/Storer.h" +#include "td/utils/StorerBase.h" #include "td/utils/tl_parsers.h" #include "td/utils/tl_storers.h" diff --git a/td/telegram/NotificationSettings.h b/td/telegram/NotificationSettings.h index 4b8036ed1..05c5e7224 100644 --- a/td/telegram/NotificationSettings.h +++ b/td/telegram/NotificationSettings.h @@ -10,6 +10,7 @@ #include "td/telegram/telegram_api.h" #include "td/utils/common.h" +#include "td/utils/Status.h" #include "td/utils/StringBuilder.h" namespace td { diff --git a/td/telegram/PasswordManager.cpp b/td/telegram/PasswordManager.cpp index adcc4d322..ff6a9a019 100644 --- a/td/telegram/PasswordManager.cpp +++ b/td/telegram/PasswordManager.cpp @@ -20,6 +20,7 @@ #include "td/utils/crypto.h" #include "td/utils/format.h" #include "td/utils/logging.h" +#include "td/utils/misc.h" #include "td/utils/Random.h" #include "td/utils/Slice.h" #include "td/utils/Time.h" @@ -394,8 +395,7 @@ void PasswordManager::check_recovery_email_address_code(string code, Promise promise) { - auto query = - G()->net_query_creator().create(create_storer(telegram_api::account_resendPasswordEmail())); + auto query = G()->net_query_creator().create(create_storer(telegram_api::account_resendPasswordEmail())); send_with_promise(std::move(query), PromiseCreator::lambda([promise = std::move(promise)](Result r_query) mutable { auto r_result = fetch_result(std::move(r_query)); diff --git a/td/telegram/SecretChatActor.cpp b/td/telegram/SecretChatActor.cpp index e924b6e00..5e784b4b1 100644 --- a/td/telegram/SecretChatActor.cpp +++ b/td/telegram/SecretChatActor.cpp @@ -31,6 +31,7 @@ #include "td/utils/overloaded.h" #include "td/utils/Random.h" #include "td/utils/ScopeGuard.h" +#include "td/utils/StorerBase.h" #include "td/utils/Time.h" #include "td/utils/tl_parsers.h" diff --git a/td/telegram/WebPagesManager.cpp b/td/telegram/WebPagesManager.cpp index 6dfb8c533..95d76089f 100644 --- a/td/telegram/WebPagesManager.cpp +++ b/td/telegram/WebPagesManager.cpp @@ -1135,7 +1135,8 @@ class WebPagesManager::PageBlockList : public PageBlock { vector items; static td_api::object_ptr get_page_block_list_item_object(const Item &item) { - return td_api::make_object(item.label.empty() ? "•" : item.label, + // if label is empty, then Bullet U+2022 is used as a label + return td_api::make_object(item.label.empty() ? "\xE2\x80\xA2" : item.label, get_page_block_objects(item.page_blocks)); } diff --git a/td/telegram/files/FileData.hpp b/td/telegram/files/FileData.hpp index 86064d908..ab34c4bce 100644 --- a/td/telegram/files/FileData.hpp +++ b/td/telegram/files/FileData.hpp @@ -8,13 +8,11 @@ #include "td/telegram/files/FileData.h" -#include "td/telegram/DialogId.h" #include "td/telegram/FileReferenceManager.h" #include "td/telegram/FileReferenceManager.hpp" #include "td/telegram/files/FileEncryptionKey.h" #include "td/telegram/files/FileLocation.h" #include "td/telegram/files/FileLocation.hpp" -#include "td/telegram/files/FileSourceId.h" #include "td/telegram/Global.h" #include "td/telegram/Td.h" diff --git a/td/telegram/logevent/LogEvent.h b/td/telegram/logevent/LogEvent.h index 96a53f7a7..a1d10f737 100644 --- a/td/telegram/logevent/LogEvent.h +++ b/td/telegram/logevent/LogEvent.h @@ -14,7 +14,7 @@ #include "td/utils/logging.h" #include "td/utils/Slice.h" #include "td/utils/Status.h" -#include "td/utils/Storer.h" +#include "td/utils/StorerBase.h" #include "td/utils/StringBuilder.h" #include "td/utils/tl_helpers.h" #include "td/utils/tl_parsers.h" diff --git a/td/telegram/logevent/SecretChatEvent.h b/td/telegram/logevent/SecretChatEvent.h index eac4da5b6..a1ef22e61 100644 --- a/td/telegram/logevent/SecretChatEvent.h +++ b/td/telegram/logevent/SecretChatEvent.h @@ -13,7 +13,6 @@ #include "td/utils/buffer.h" #include "td/utils/format.h" #include "td/utils/logging.h" -#include "td/utils/Storer.h" #include "td/utils/StringBuilder.h" #include "td/utils/tl_helpers.h" diff --git a/td/telegram/net/NetQueryCreator.h b/td/telegram/net/NetQueryCreator.h index 6cc4975d8..41c18041f 100644 --- a/td/telegram/net/NetQueryCreator.h +++ b/td/telegram/net/NetQueryCreator.h @@ -12,7 +12,7 @@ #include "td/utils/buffer.h" #include "td/utils/ObjectPool.h" -#include "td/utils/Storer.h" +#include "td/utils/StorerBase.h" namespace td { diff --git a/tddb/td/db/BinlogKeyValue.h b/tddb/td/db/BinlogKeyValue.h index 9cf2c917f..970e57ab0 100644 --- a/tddb/td/db/BinlogKeyValue.h +++ b/tddb/td/db/BinlogKeyValue.h @@ -19,6 +19,7 @@ #include "td/utils/port/RwMutex.h" #include "td/utils/Slice.h" #include "td/utils/Status.h" +#include "td/utils/StorerBase.h" #include "td/utils/tl_parsers.h" #include "td/utils/tl_storers.h" diff --git a/tddb/td/db/binlog/BinlogEvent.h b/tddb/td/db/binlog/BinlogEvent.h index 75f8102ab..120f9e746 100644 --- a/tddb/td/db/binlog/BinlogEvent.h +++ b/tddb/td/db/binlog/BinlogEvent.h @@ -13,6 +13,7 @@ #include "td/utils/Slice.h" #include "td/utils/Status.h" #include "td/utils/Storer.h" +#include "td/utils/StorerBase.h" #include "td/utils/StringBuilder.h" namespace td { diff --git a/tddb/td/db/binlog/BinlogHelper.h b/tddb/td/db/binlog/BinlogHelper.h index 78ea564d6..04399e098 100644 --- a/tddb/td/db/binlog/BinlogHelper.h +++ b/tddb/td/db/binlog/BinlogHelper.h @@ -11,7 +11,6 @@ #include "td/db/binlog/BinlogEvent.h" #include "td/utils/common.h" -#include "td/utils/Storer.h" namespace td { diff --git a/tdnet/td/net/GetHostByNameActor.cpp b/tdnet/td/net/GetHostByNameActor.cpp index 3208bbbe2..b8a02ce01 100644 --- a/tdnet/td/net/GetHostByNameActor.cpp +++ b/tdnet/td/net/GetHostByNameActor.cpp @@ -6,11 +6,13 @@ // #include "td/net/GetHostByNameActor.h" +#include "td/net/HttpQuery.h" #include "td/net/SslStream.h" #include "td/net/Wget.h" #include "td/utils/JsonBuilder.h" #include "td/utils/logging.h" +#include "td/utils/misc.h" #include "td/utils/Slice.h" #include "td/utils/Time.h" @@ -134,7 +136,7 @@ void GetHostByNameActor::run(string host, int port, bool prefer_ipv6, Promisesecond; auto begin_time = Time::now(); - if (value.expire_at > begin_time) { + if (value.expires_at > begin_time) { return promise.set_result(value.get_ip_port(port)); } diff --git a/tdnet/td/net/GetHostByNameActor.h b/tdnet/td/net/GetHostByNameActor.h index 0d8883dc5..7faa8fd0f 100644 --- a/tdnet/td/net/GetHostByNameActor.h +++ b/tdnet/td/net/GetHostByNameActor.h @@ -14,6 +14,7 @@ #include "td/utils/Status.h" #include +#include namespace td { @@ -42,9 +43,9 @@ class GetHostByNameActor final : public Actor { struct Value { Result ip; - double expire_at; + double expires_at; - Value(Result ip, double expire_at) : ip(std::move(ip)), expire_at(expire_at) { + Value(Result ip, double expires_at) : ip(std::move(ip)), expires_at(expires_at) { } Result get_ip_port(int port) const {