1 Aug
2015
1 Aug
'15
8:53 p.m.
Hello list! Does anyone know if there is a way to track changes to the call state, most notably a hangup, while executing Javascript? We're using JS to set up a call on a device connected to Freeswitch through portaudio. That call is initiated with sip/sofia executing the JS in the dialplan. If the SIP leg hangs up while the JS is running, nothing happens until the JS terminates. I wanted to check from the script, but haven't found a way to do that. "session.state" doesn't change, hangup hook doesn't fire, and without setTimeout or something similar I didn't find a way to "background" the JS. Is there any way to detect a hangup during JS execution? Cheers! Thomas