From d26ac24256947c189980c6246ce7c9bf4ac552bc Mon Sep 17 00:00:00 2001 From: Andreas Granig Date: Fri, 3 Oct 2014 13:40:25 +0200 Subject: [PATCH] Play prompt if dir is empty. --- apps/app_voicemail.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c index 24572df..6c5e162 100644 --- a/apps/app_voicemail.c +++ b/apps/app_voicemail.c @@ -7840,6 +7840,15 @@ static int vm_execmain(struct ast_channel *chan, void *data) break; default: /* Nothing */ ast_log(LOG_NOTICE, "+++++ default action, play instructions\n"); + if (!vms.oldmessages && !vms.newmessages) { + if(!strcasecmp(chan->language, "ro")) { + ast_play_and_wait(chan, "vm-dir-empty"); + } else { + res = ast_play_and_wait(chan, "vm-no"); + if (!res) + res = ast_play_and_wait(chan, "vm-messages"); + } + } cmd = vm_instructions(chan, &vms, 0); break; }