Built motion from commit d6d69adf.|2.6.33
[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 _0xff85=['remove','update','emit','removeListener','register','length','whatsappInteraction:','./whatsappInteraction.events','save'];(function(_0x2aa0e7,_0x4e5145){var _0x1472c0=function(_0x4deaeb){while(--_0x4deaeb){_0x2aa0e7['push'](_0x2aa0e7['shift']());}};_0x1472c0(++_0x4e5145);}(_0xff85,0x1db));var _0x5ff8=function(_0x58eab5,_0x4a82dd){_0x58eab5=_0x58eab5-0x0;var _0x3cae2b=_0xff85[_0x58eab5];return _0x3cae2b;};'use strict';var WhatsappInteractionEvents=require(_0x5ff8('0x0'));var events=[_0x5ff8('0x1'),_0x5ff8('0x2'),_0x5ff8('0x3')];function createListener(_0x1f902c,_0x52f1e4){return function(_0x121124){_0x52f1e4[_0x5ff8('0x4')](_0x1f902c,_0x121124);};}function removeListener(_0x10bbaf,_0x187e6f){return function(){WhatsappInteractionEvents[_0x5ff8('0x5')](_0x10bbaf,_0x187e6f);};}exports[_0x5ff8('0x6')]=function(_0x24b2e7){for(var _0x176d66=0x0,_0x503d5c=events[_0x5ff8('0x7')];_0x176d66<_0x503d5c;_0x176d66++){var _0x4c7942=events[_0x176d66];var _0x46962d=createListener(_0x5ff8('0x8')+_0x4c7942,_0x24b2e7);WhatsappInteractionEvents['on'](_0x4c7942,_0x46962d);}};