Fix crash in link preview edit.

This commit is contained in:
John Preston 2023-11-02 16:44:41 +04:00
parent 8ebf329cd9
commit b41c94be29
1 changed files with 4 additions and 3 deletions

View File

@ -638,10 +638,11 @@ void DraftOptionsBox(
const auto &highlight = args.highlight;
const auto &clearOldDraft = args.clearOldDraft;
const auto resolveReply = [=] {
const auto current = state->quote.current();
auto result = draft.reply;
result.messageId = current.item->fullId();
result.quote = current.text;
if (const auto current = state->quote.current()) {
result.messageId = current.item->fullId();
result.quote = current.text;
}
return result;
};
const auto finish = [=](