fix nextjs webhook example num_endpoints null check

This commit is contained in:
Captain Caius
2025-07-08 13:40:26 -07:00
parent d98b6b418d
commit c0ed061ff5

View File

@@ -103,7 +103,7 @@ export default async function handler(req, res) {
const sip_config = {
display_name: From,
sip_mode: 'dial-in',
num_endpoints: call_transfer !== null ? 2 : 1,
num_endpoints: (call_transfer !== undefined && call_transfer !== null) ? 2 : 1,
codecs: {"audio": ["OPUS"]},
};
daily_room_properties.sip = sip_config;