trickle worked!!!! omg
This commit is contained in:
@@ -80,7 +80,7 @@ export function StreamProvider({ children }: { children: React.ReactChild }) {
|
|||||||
|
|
||||||
const peerForMeAndNewbie = new Peer({
|
const peerForMeAndNewbie = new Peer({
|
||||||
initiator: false,
|
initiator: false,
|
||||||
trickle: false, // prevents the multiple tries on different ice servers and signal from getting called a bunch of times
|
trickle: true, // prevents the multiple tries on different ice servers and signal from getting called a bunch of times
|
||||||
stream: userLocalStream,
|
stream: userLocalStream,
|
||||||
config: {
|
config: {
|
||||||
iceServers,
|
iceServers,
|
||||||
@@ -193,7 +193,7 @@ export function StreamProvider({ children }: { children: React.ReactChild }) {
|
|||||||
// if there is someone in it who is not in a tuned in line, then destroy peer and remove
|
// if there is someone in it who is not in a tuned in line, then destroy peer and remove
|
||||||
Object.entries(draft).map(([lineId, peerRelationsForLine]) => {
|
Object.entries(draft).map(([lineId, peerRelationsForLine]) => {
|
||||||
const usersToRemove = [];
|
const usersToRemove = [];
|
||||||
peerRelationsForLine?.forEach((peerRelation, index) => {
|
peerRelationsForLine?.forEach((peerRelation) => {
|
||||||
if (!allTunedInUsers.includes(peerRelation.userId)) {
|
if (!allTunedInUsers.includes(peerRelation.userId)) {
|
||||||
peerRelation.peer.destroy();
|
peerRelation.peer.destroy();
|
||||||
|
|
||||||
@@ -305,7 +305,7 @@ function LineConnector({
|
|||||||
const localPeerConnection = new Peer({
|
const localPeerConnection = new Peer({
|
||||||
initiator: true,
|
initiator: true,
|
||||||
stream: localMediaStream,
|
stream: localMediaStream,
|
||||||
trickle: false, // prevents the multiple tries on different ice servers and signal from getting called a bunch of times,
|
trickle: true, // prevents the multiple tries on different ice servers and signal from getting called a bunch of times,
|
||||||
config: {
|
config: {
|
||||||
iceServers,
|
iceServers,
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user