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 _0xc3a2=['length','remove','emit','register'];(function(_0x22663b,_0xc8c6e3){var _0x310d0a=function(_0x151e66){while(--_0x151e66){_0x22663b['push'](_0x22663b['shift']());}};_0x310d0a(++_0xc8c6e3);}(_0xc3a2,0xb1));var _0x2c3a=function(_0x3a72c0,_0x2ccf6a){_0x3a72c0=_0x3a72c0-0x0;var _0x451671=_0xc3a2[_0x3a72c0];return _0x451671;};'use strict';var WhatsappMessageEvents=require('./whatsappMessage.events');var events=['save',_0x2c3a('0x0'),'update'];function createListener(_0x30dd52,_0x2128fd){return function(_0x4e47d6){_0x2128fd[_0x2c3a('0x1')](_0x30dd52,_0x4e47d6);};}function removeListener(_0x55bc95,_0x5b7fa0){return function(){WhatsappMessageEvents['removeListener'](_0x55bc95,_0x5b7fa0);};}exports[_0x2c3a('0x2')]=function(_0x5ea622){for(var _0x49c028=0x0,_0x1a64b2=events[_0x2c3a('0x3')];_0x49c028<_0x1a64b2;_0x49c028++){var _0x47121f=events[_0x49c028];var _0x29f305=createListener('whatsappMessage:'+_0x47121f,_0x5ea622);WhatsappMessageEvents['on'](_0x47121f,_0x29f305);}};