mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 14:38:15 +00:00
Support sponsored peers in search results.
This commit is contained in:
@@ -106,9 +106,10 @@ void PeerSearch::requestSponsored() {
|
||||
parsed.sponsored.push_back({
|
||||
.peer = _session->data().peer(peerId),
|
||||
.randomId = data.vrandom_id().v,
|
||||
.sponsorInfo = qs(data.vsponsor_info().value_or_empty()),
|
||||
.additionalInfo = qs(
|
||||
data.vadditional_info().value_or_empty()),
|
||||
.sponsorInfo = TextWithEntities::Simple(
|
||||
qs(data.vsponsor_info().value_or_empty())),
|
||||
.additionalInfo = TextWithEntities::Simple(
|
||||
qs(data.vadditional_info().value_or_empty())),
|
||||
});
|
||||
}
|
||||
finishSponsored(requestId, std::move(parsed));
|
||||
|
@@ -16,8 +16,8 @@ namespace Api {
|
||||
struct SponsoredSearchResult {
|
||||
not_null<PeerData*> peer;
|
||||
QByteArray randomId;
|
||||
QString sponsorInfo;
|
||||
QString additionalInfo;
|
||||
TextWithEntities sponsorInfo;
|
||||
TextWithEntities additionalInfo;
|
||||
};
|
||||
|
||||
struct PeerSearchResult {
|
||||
|
Reference in New Issue
Block a user