fix: SIP Options monitor would always write an error to log because sipsak by default writes DEBUG to stderr

pull/5362/head
Eddie Fiorentine 2 weeks ago
parent c40f8e7ba5
commit 783e228406

@ -31,9 +31,6 @@ class SIPMonitorType extends MonitorType {
*/
async runSipSak(hostname, port, timeout) {
const { stdout, stderr } = await exec(`sipsak -s sip:${hostname}:${port} --from sip:sipsak@${hostname} -v`,{timeout:timeout});
if (stderr){
console.error(`Error in stderr: ${stderr.toString()}`);
}
if (!stdout && stderr && stderr.toString()) {
throw new Error(`Error in output: ${stderr.toString()}`);
}

Loading…
Cancel
Save