Built motion from commit 87cd5f02.|2.5.48
[motion2.git] / server / api / whatsappInteraction / whatsappInteraction.socket.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
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.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xbc3d=['register','length','whatsappInteraction:','./whatsappInteraction.events','save','remove','update','emit'];(function(_0x5dee4f,_0x3b9ca2){var _0x24423e=function(_0x31d213){while(--_0x31d213){_0x5dee4f['push'](_0x5dee4f['shift']());}};_0x24423e(++_0x3b9ca2);}(_0xbc3d,0x1cb));var _0xdbc3=function(_0x349a9e,_0x473cb8){_0x349a9e=_0x349a9e-0x0;var _0x24c207=_0xbc3d[_0x349a9e];return _0x24c207;};'use strict';var WhatsappInteractionEvents=require(_0xdbc3('0x0'));var events=[_0xdbc3('0x1'),_0xdbc3('0x2'),_0xdbc3('0x3')];function createListener(_0x32c6bd,_0x59150f){return function(_0x369ce0){_0x59150f[_0xdbc3('0x4')](_0x32c6bd,_0x369ce0);};}function removeListener(_0x2f046f,_0x3aa45b){return function(){WhatsappInteractionEvents['removeListener'](_0x2f046f,_0x3aa45b);};}exports[_0xdbc3('0x5')]=function(_0x3a22ad){for(var _0x22c58a=0x0,_0x4528ad=events[_0xdbc3('0x6')];_0x22c58a<_0x4528ad;_0x22c58a++){var _0x24c99c=events[_0x22c58a];var _0x297794=createListener(_0xdbc3('0x7')+_0x24c99c,_0x3a22ad);WhatsappInteractionEvents['on'](_0x24c99c,_0x297794);}};