diff --git a/src/pbx/handlers/PageDTMF.ts b/src/pbx/handlers/PageDTMF.ts index c373eba..74ea7d2 100644 --- a/src/pbx/handlers/PageDTMF.ts +++ b/src/pbx/handlers/PageDTMF.ts @@ -24,14 +24,15 @@ export default class PageDTMF extends Handler { const pagerNumber: string[] = []; const pagerCode: string[] = []; channel.answer(); - const pnPlayback = await channel.play({ + const pnPlaybackC = this.pbx.ari.Playback(); + channel.play({ media: 'sound:please-enter-the-pn', - }, undefined); + }, pnPlaybackC); channel.on('ChannelDtmfReceived', async (ev) => { if (!channel.connected) return; if (status === 0) { if (ev.digit === '#') { - await pnPlayback.stop(); + await pnPlaybackC.stop(); await channel.play({ media: 'sound:please-enter-the-pc', }, undefined);