Skip to content

Commit

Permalink
Trying to prevent candidates before offer
Browse files Browse the repository at this point in the history
  • Loading branch information
daonb committed Nov 22, 2023
1 parent 0ef0a72 commit 46318f1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/webrtc_session.ts
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,6 @@ export class PeerbookSession extends WebRTCSession {
this.onStateChange("failed", Failure.InternalError)
return
}
this.pc.setLocalDescription(d)
try {
await terminal7.pb.adminCommand({type: "offer",
args: {
Expand All @@ -451,7 +450,9 @@ export class PeerbookSession extends WebRTCSession {
} catch(e) {
terminal7.log("failed to send offer", e)
this.onStateChange("failed", e)
return
}
this.pc.setLocalDescription(d)
}
peerAnswer(offer) {
const sd = new RTCSessionDescription(offer)
Expand Down

0 comments on commit 46318f1

Please sign in to comment.