diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 566c496..5efff01 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -1,4 +1,4 @@ contact_links: - name: You have a question about the Telegram API or how to do something with WTelegramClient? - url: https://stackoverflow.com/questions/ask?tags=wtelegramclient+telegram-api + url: https://stackoverflow.com/questions/ask?tags=c%23+wtelegramclient+telegram-api about: The answer to your question can be helpful to the community so it's better to ask them on StackOverflow ---> diff --git a/src/TL.Helpers.cs b/src/TL.Helpers.cs index bc2ba15..bf6a1f6 100644 --- a/src/TL.Helpers.cs +++ b/src/TL.Helpers.cs @@ -343,9 +343,9 @@ namespace TL { message = new Message { - flags = (Message.Flags)flags | Message.Flags.has_from_id, id = id, date = date, + flags = (Message.Flags)flags | (flags.HasFlag(Flags.out_) ? 0 : Message.Flags.has_from_id), id = id, date = date, message = message, entities = entities, reply_to = reply_to, - from_id = new PeerUser { user_id = user_id }, + from_id = flags.HasFlag(Flags.out_) ? null : new PeerUser { user_id = user_id }, peer_id = new PeerUser { user_id = user_id }, fwd_from = fwd_from, via_bot_id = via_bot_id, ttl_period = ttl_period }, pts = pts, pts_count = pts_count