mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-14 05:07:10 +02:00
Fix shortcut messages incorrect processing.
This commit is contained in:
parent
7f4b540aad
commit
37283a7a35
2 changed files with 5 additions and 3 deletions
|
@ -449,9 +449,6 @@ void ShortcutMessages::preloadShortcuts() {
|
|||
result.match([&](const MTPDmessages_quickReplies &data) {
|
||||
owner->processUsers(data.vusers());
|
||||
owner->processChats(data.vchats());
|
||||
owner->processMessages(
|
||||
data.vmessages(),
|
||||
NewMessageType::Existing);
|
||||
updateShortcuts(data.vquick_replies().v);
|
||||
}, [&](const MTPDmessages_quickRepliesNotModified &) {
|
||||
if (!_shortcutsLoaded) {
|
||||
|
|
|
@ -42,6 +42,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
|||
#include "boxes/send_credits_box.h"
|
||||
#include "api/api_text_entities.h"
|
||||
#include "api/api_updates.h"
|
||||
#include "data/business/data_shortcut_messages.h"
|
||||
#include "data/components/scheduled_messages.h"
|
||||
#include "data/components/sponsored_messages.h"
|
||||
#include "data/notify/data_notify_settings.h"
|
||||
|
@ -713,6 +714,10 @@ HistoryItem::HistoryItem(
|
|||
, _date(fields.date)
|
||||
, _shortcutId(fields.shortcutId)
|
||||
, _effectId(fields.effectId) {
|
||||
Expects(!_shortcutId
|
||||
|| isSending()
|
||||
|| _history->owner().shortcutMessages().lookupId(this));
|
||||
|
||||
if (isHistoryEntry() && IsClientMsgId(id)) {
|
||||
_history->registerClientSideMessage(this);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue