diff --git a/Telegram/SourceFiles/api/api_sending.cpp b/Telegram/SourceFiles/api/api_sending.cpp index a0d6f4d957..850f21656b 100644 --- a/Telegram/SourceFiles/api/api_sending.cpp +++ b/Telegram/SourceFiles/api/api_sending.cpp @@ -42,6 +42,9 @@ void InnerFillMessagePostFlags( not_null peer, MessageFlags &flags) { const auto anonymousPost = peer->amAnonymous(); + if (ShouldSendSilent(peer, options)) { + flags |= MessageFlag::Silent; + } if (!anonymousPost || options.sendAs) { flags |= MessageFlag::HasFromId; return; @@ -401,9 +404,6 @@ void SendConfirmedFile( const auto anonymousPost = peer->amAnonymous(); const auto silentPost = ShouldSendSilent(peer, file->to.options); FillMessagePostFlags(action, peer, flags); - if (silentPost) { - flags |= MessageFlag::Silent; - } if (file->to.options.scheduled) { flags |= MessageFlag::IsOrWasScheduled;