I got the same message twice

后端 未结 2 519
一生所求
一生所求 2021-01-25 10:57

I used this code to send a different message if a new user start conversation :

IConversationUpdateActivity update = message;
            var client = new Connec         


        
2条回答
  •  被撕碎了的回忆
    2021-01-25 11:49

    Facebook includes the conversation itself in the list of members:

    So you need to change the if statement to this:

    if (newMember.Id != message.Recipient.Id && newMember.Id != message.Conversation.Id)
    { 
       // send welcome message
    

提交回复
热议问题