Skip to content

Commit

Permalink
merged headers for InternalCreateSIPParticipantRequest
Browse files Browse the repository at this point in the history
  • Loading branch information
s-hamdananwar committed Dec 6, 2024
1 parent e637244 commit abd6e68
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion rpc/sip.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ func NewCreateSIPParticipantRequest(
features = append(features, livekit.SIPFeature_KRISP_ENABLED)
}

headers := req.Headers
if headers == nil {
headers = trunk.Headers
}

return &InternalCreateSIPParticipantRequest{
ProjectId: projectID,
SipCallId: callID,
Expand All @@ -74,7 +79,7 @@ func NewCreateSIPParticipantRequest(
ParticipantAttributes: attrs,
Dtmf: req.Dtmf,
PlayDialtone: req.PlayRingtone || req.PlayDialtone,
Headers: trunk.Headers,
Headers: headers,
HeadersToAttributes: trunk.HeadersToAttributes,
AttributesToHeaders: trunk.AttributesToHeaders,
EnabledFeatures: features,
Expand Down

0 comments on commit abd6e68

Please sign in to comment.