1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold. *
17 // *************************************************************************
18 var _0xfcfb=['remove','update','emit','removeListener','register','./whatsappQueue.events'];(function(_0x293490,_0x389352){var _0x240e5f=function(_0x33805d){while(--_0x33805d){_0x293490['push'](_0x293490['shift']());}};_0x240e5f(++_0x389352);}(_0xfcfb,0x173));var _0xbfcf=function(_0x2ab5d7,_0x1243d9){_0x2ab5d7=_0x2ab5d7-0x0;var _0x516388=_0xfcfb[_0x2ab5d7];return _0x516388;};'use strict';var WhatsappQueueEvents=require(_0xbfcf('0x0'));var events=['save',_0xbfcf('0x1'),_0xbfcf('0x2')];function createListener(_0x234ed9,_0x383bd1){return function(_0x7d30f){_0x383bd1[_0xbfcf('0x3')](_0x234ed9,_0x7d30f);};}function removeListener(_0x1a16ed,_0x4c3e3c){return function(){WhatsappQueueEvents[_0xbfcf('0x4')](_0x1a16ed,_0x4c3e3c);};}exports[_0xbfcf('0x5')]=function(_0x46676f){for(var _0x4846ad=0x0,_0x2dc8eb=events['length'];_0x4846ad<_0x2dc8eb;_0x4846ad++){var _0x7fdd9a=events[_0x4846ad];var _0x85f47e=createListener('whatsappQueue:'+_0x7fdd9a,_0x46676f);WhatsappQueueEvents['on'](_0x7fdd9a,_0x85f47e);}};