@@ -422,7 +422,7 @@ void ChatParticipants::requestForAdd(
422422
423423 _forAdd.channel = channel;
424424 _forAdd.requestId = _api.request (MTPchannels_GetParticipants (
425- channel->inputChannel ,
425+ channel->inputChannel () ,
426426 MTP_channelParticipantsRecent (),
427427 MTP_int (offset),
428428 MTP_int (channel->session ().serverConfig ().chatSizeMax ),
@@ -450,7 +450,7 @@ void ChatParticipants::requestLast(not_null<ChannelData*> channel) {
450450 const auto offset = 0 ;
451451 const auto participantsHash = uint64 (0 );
452452 const auto requestId = _api.request (MTPchannels_GetParticipants (
453- channel->inputChannel ,
453+ channel->inputChannel () ,
454454 MTP_channelParticipantsRecent (),
455455 MTP_int (offset),
456456 MTP_int (channel->session ().serverConfig ().chatSizeMax ),
@@ -480,7 +480,7 @@ void ChatParticipants::requestBots(not_null<ChannelData*> channel) {
480480 const auto offset = 0 ;
481481 const auto participantsHash = uint64 (0 );
482482 const auto requestId = _api.request (MTPchannels_GetParticipants (
483- channel->inputChannel ,
483+ channel->inputChannel () ,
484484 MTP_channelParticipantsBots (),
485485 MTP_int (offset),
486486 MTP_int (channel->session ().serverConfig ().chatSizeMax ),
@@ -516,7 +516,7 @@ void ChatParticipants::requestAdmins(not_null<ChannelData*> channel) {
516516 const auto offset = 0 ;
517517 const auto participantsHash = uint64 (0 );
518518 const auto requestId = _api.request (MTPchannels_GetParticipants (
519- channel->inputChannel ,
519+ channel->inputChannel () ,
520520 MTP_channelParticipantsAdmins (),
521521 MTP_int (offset),
522522 MTP_int (channel->session ().serverConfig ().chatSizeMax ),
@@ -555,8 +555,8 @@ void ChatParticipants::add(
555555 if (const auto chat = peer->asChat ()) {
556556 for (const auto &user : users) {
557557 _api.request (MTPmessages_AddChatUser (
558- chat->inputChat ,
559- user->inputUser ,
558+ chat->inputChat () ,
559+ user->inputUser () ,
560560 MTP_int (passGroupHistory ? kForwardMessagesOnAdd : 0 )
561561 )).done ([=](const MTPmessages_InvitedUsers &result) {
562562 const auto &data = result.data ();
@@ -587,7 +587,7 @@ void ChatParticipants::add(
587587 const auto send = [&] {
588588 const auto callback = base::take (done);
589589 _api.request (MTPchannels_InviteToChannel (
590- channel->inputChannel ,
590+ channel->inputChannel () ,
591591 MTP_vector<MTPInputUser>(list)
592592 )).done ([=](const MTPmessages_InvitedUsers &result) {
593593 const auto &data = result.data ();
@@ -606,7 +606,7 @@ void ChatParticipants::add(
606606 }).afterDelay (kSmallDelayMs ).send ();
607607 };
608608 for (const auto &user : users) {
609- list.push_back (user->inputUser );
609+ list.push_back (user->inputUser () );
610610 if (list.size () == kMaxUsersPerInvite ) {
611611 send ();
612612 list.clear ();
@@ -653,8 +653,8 @@ void ChatParticipants::Restrict(
653653 Fn<void ()> onDone,
654654 Fn<void()> onFail) {
655655 channel->session ().api ().request (MTPchannels_EditBanned (
656- channel->inputChannel ,
657- participant->input ,
656+ channel->inputChannel () ,
657+ participant->input () ,
658658 RestrictionsToMTP (newRights)
659659 )).done ([=](const MTPUpdates &result) {
660660 channel->session ().api ().applyUpdates (result);
@@ -692,7 +692,7 @@ void ChatParticipants::requestSelf(not_null<ChannelData*> channel) {
692692 };
693693 _selfParticipantRequests.emplace (channel);
694694 _api.request (MTPchannels_GetParticipant (
695- channel->inputChannel ,
695+ channel->inputChannel () ,
696696 MTP_inputPeerSelf ()
697697 )).done ([=](const MTPchannels_ChannelParticipant &result) {
698698 _selfParticipantRequests.erase (channel);
@@ -742,8 +742,8 @@ void ChatParticipants::kick(
742742
743743 _api.request (MTPmessages_DeleteChatUser (
744744 MTP_flags (0 ),
745- chat->inputChat ,
746- participant->asUser ()->inputUser
745+ chat->inputChat () ,
746+ participant->asUser ()->inputUser ()
747747 )).done ([=](const MTPUpdates &result) {
748748 chat->session ().api ().applyUpdates (result);
749749 }).send ();
@@ -758,8 +758,8 @@ void ChatParticipants::kick(
758758
759759 const auto rights = ChannelData::KickedRestrictedRights (participant);
760760 const auto requestId = _api.request (MTPchannels_EditBanned (
761- channel->inputChannel ,
762- participant->input ,
761+ channel->inputChannel () ,
762+ participant->input () ,
763763 RestrictionsToMTP (rights)
764764 )).done ([=](const MTPUpdates &result) {
765765 channel->session ().api ().applyUpdates (result);
@@ -782,8 +782,8 @@ void ChatParticipants::unblock(
782782 }
783783
784784 const auto requestId = _api.request (MTPchannels_EditBanned (
785- channel->inputChannel ,
786- participant->input ,
785+ channel->inputChannel () ,
786+ participant->input () ,
787787 MTP_chatBannedRights (MTP_flags (0 ), MTP_int (0 ))
788788 )).done ([=](const MTPUpdates &result) {
789789 channel->session ().api ().applyUpdates (result);
@@ -814,7 +814,7 @@ void ChatParticipants::loadSimilarPeers(not_null<PeerData*> peer) {
814814 _similar[peer].requestId = _api.request (
815815 MTPchannels_GetChannelRecommendations (
816816 MTP_flags (Flag::f_channel),
817- channel->inputChannel )
817+ channel->inputChannel () )
818818 ).done ([=](const MTPmessages_Chats &result) {
819819 auto &similar = _similar[channel];
820820 similar.requestId = 0 ;
@@ -832,7 +832,7 @@ void ChatParticipants::loadSimilarPeers(not_null<PeerData*> peer) {
832832 }).send ();
833833 } else if (const auto bot = peer->asBot ()) {
834834 _similar[peer].requestId = _api.request (
835- MTPbots_GetBotRecommendations (bot->inputUser )
835+ MTPbots_GetBotRecommendations (bot->inputUser () )
836836 ).done ([=](const MTPusers_Users &result) {
837837 auto &similar = _similar[peer];
838838 similar.requestId = 0 ;
0 commit comments