feat(wsService, WebRTCManager): enhance call handling with media type support and negotiation improvements
- Added optional media_type to WSCallIncomingMessage for better call type differentiation. - Updated call_type assignment in WebSocketService to prioritize media_type if available. - Removed initialOfferCreated flag in WebRTCManager to simplify negotiation logic. - Improved negotiation handling by releasing the negotiation lock after offer creation, ensuring smoother call setup.
This commit is contained in:
@@ -48,6 +48,7 @@ export interface WSCallIncomingMessage {
|
||||
conversation_id: string;
|
||||
caller_id: string;
|
||||
call_type: string;
|
||||
media_type?: string;
|
||||
created_at: number;
|
||||
lifetime?: number;
|
||||
ice_servers?: ICEServerConfig[];
|
||||
@@ -621,7 +622,7 @@ class WebSocketService {
|
||||
call_id: payload.call_id,
|
||||
conversation_id: payload.conversation_id,
|
||||
caller_id: payload.caller_id,
|
||||
call_type: payload.call_type,
|
||||
call_type: payload.media_type || payload.call_type,
|
||||
created_at: payload.created_at,
|
||||
lifetime: payload.lifetime,
|
||||
ice_servers: payload.ice_servers,
|
||||
|
||||
Reference in New Issue
Block a user