Reputation: 1795
I'm implementing Twilio's Programmable Chat using the Android SDK.
When the Chat is setup I create a new Channel (using channelBuilder()
), and then join it (calling join()
). Then I set the channel listener and I call channel.getMembers().inviteByIdentity(userId)
but that crashes because channel.getMembers() returns null.
Do I have to call inviteByIdentity(userId)
on a different place?
Upvotes: 0
Views: 131
Reputation: 1795
Moved channel.getMembers().inviteByIdentity(userId)
to ChannelListener.onSynchronizationChanged(Channel channel)
method and it now works!
Should have tried this before…
Upvotes: 1