feat: replace webrtc with ws relay
This commit is contained in:
@@ -302,6 +302,17 @@ class WatchTogetherProvider with ChangeNotifier {
|
||||
);
|
||||
}
|
||||
|
||||
// If we're the host, send our join info back so the new peer
|
||||
// adds us to their participant list. This is done at provider
|
||||
// level (in addition to sync manager) so it works even when
|
||||
// no player is attached yet.
|
||||
if (isHost && _peerService != null) {
|
||||
_peerService!.sendTo(
|
||||
message.peerId!,
|
||||
SyncMessage.join(peerId: _peerService!.myPeerId!, displayName: _displayName, isHost: true),
|
||||
);
|
||||
}
|
||||
|
||||
notifyListeners();
|
||||
}
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user