File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2484,16 +2484,18 @@ <h3>Transfer Call</h3>
24842484 const bodyStr = JSON . stringify ( parsed ) ;
24852485
24862486 try {
2487- // JsSIP 3.x sends custom INFO via session.sendRequest().
2488- // Fallback: if that fails, try constructing the request through the UA.
2487+ // JsSIP 3.x: RTCSession.sendRequest() drops the `contentType`
2488+ // option — it only forwards `extraHeaders` and `body` to the
2489+ // dialog. So the Content-Type header MUST be supplied via
2490+ // extraHeaders, otherwise the server receives ct=None.
2491+ const extraHeaders = [ 'Content-Type: ' + contentType ] ;
24892492 if ( typeof session . sendRequest === 'function' ) {
24902493 session . sendRequest ( 'INFO' , {
2494+ extraHeaders : extraHeaders ,
24912495 body : bodyStr ,
2492- contentType : contentType ,
24932496 } ) ;
24942497 } else {
24952498 // Older JsSIP API: use session.request.sendRequest directly
2496- const extraHeaders = [ 'Content-Type: ' + contentType ] ;
24972499 session . request . sendRequest ( 'INFO' , {
24982500 extraHeaders : extraHeaders ,
24992501 body : bodyStr ,
You can’t perform that action at this time.
0 commit comments