2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 22:55:11 +00:00

Simplified extracting of data from some MTP* responses.

This commit is contained in:
23rd
2022-07-10 17:59:52 +03:00
committed by John Preston
parent 44a7d11e4a
commit 89a3462824
5 changed files with 7 additions and 26 deletions

View File

@@ -100,10 +100,7 @@ void SendBotCallbackData(
button->requestId = 0;
owner->requestItemRepaint(item);
}
const auto &data = result.match([](
const auto &data) -> const MTPDmessages_botCallbackAnswer& {
return data;
});
const auto &data = result.data();
const auto message = data.vmessage()
? qs(*data.vmessage())
: QString();