Blind transfer to an extension that doesn't have voicemail if it timesout send the call back.
This commit is contained in:
@@ -269,8 +269,12 @@
|
|||||||
send_email(voicemail_id, uuid);
|
send_email(voicemail_id, uuid);
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
--invalid voicemail
|
--voicemail not enabled or does not exist
|
||||||
session:hangup();
|
referred_by = session:getVariable("sip_h_Referred-By");
|
||||||
|
referred_by = referred_by:match('[%d]+');
|
||||||
|
if (referred_by) then
|
||||||
|
session:transfer(referred_by, "XML", context);
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user