switch_cc_t cc = { 0 };
switch_codec_implementation_t read_impl = { 0 };
int got_file = 0;
- switch_bool_t skip_record_check = switch_true(switch_channel_get_variable(channel, "skip_record_check"));
+ switch_bool_t skip_record_check = switch_channel_var_true(channel, "skip_record_check");
switch_core_session_get_read_impl(session, &read_impl);
cid_buf, switch_channel_get_name(channel));
switch_core_session_receive_message(session, &msg);
- if (!zstr(cbt->cid_number) && (switch_true(switch_channel_get_variable(channel, "vm_announce_cid")))) {
+ if (!zstr(cbt->cid_number) && (switch_channel_var_true(channel, "vm_announce_cid"))) {
TRY_CODE(switch_ivr_phrase_macro(session, VM_SAY_PHONE_NUMBER_MACRO, cbt->cid_number, NULL, NULL));
}
auth_only = 1;
auth = 0;
} else {
- auth_only = switch_true(switch_channel_get_variable(channel, "vm_auth_only"));
+ auth_only = switch_channel_var_true(channel, "vm_auth_only");
}
timeout = profile->digit_timeout;
switch_event_t *vars = NULL;
const char *vtmp, *vm_ext = NULL;
int disk_quota = 0;
- switch_bool_t skip_greeting = switch_true(switch_channel_get_variable(channel, "skip_greeting"));
- switch_bool_t skip_instructions = switch_true(switch_channel_get_variable(channel, "skip_instructions"));
- switch_bool_t skip_record_urgent_check = switch_true(switch_channel_get_variable(channel, "skip_record_urgent_check"));
+ switch_bool_t skip_greeting = switch_channel_var_true(channel, "skip_greeting");
+ switch_bool_t skip_instructions = switch_channel_var_true(channel, "skip_instructions");
+ switch_bool_t skip_record_urgent_check = switch_channel_var_true(channel, "skip_record_urgent_check");
+ switch_bool_t voicemail_skip_goodbye = switch_channel_var_true(channel, "voicemail_skip_goodbye");
switch_bool_t vm_enabled = SWITCH_TRUE;
switch_channel_set_variable(channel, "skip_greeting", NULL);
switch_channel_set_variable(channel, "skip_instructions", NULL);
switch_channel_set_variable(channel, "skip_record_urgent_check", NULL);
+ switch_channel_set_variable(channel, "voicemail_skip_goodbye", NULL);
memset(&cbt, 0, sizeof(cbt));
switch_safe_free(file_path);
if (switch_channel_ready(channel) && vm_enabled) {
- status = switch_ivr_phrase_macro(session, VM_GOODBYE_MACRO, NULL, NULL, NULL);
+ if (!voicemail_skip_goodbye) {
+ status = switch_ivr_phrase_macro(session, VM_GOODBYE_MACRO, NULL, NULL, NULL);
+ }
}
return status;