Built motion from commit 25580385.|2.6.2
[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 _0x15d2=['update','emit','register','length','whatsappInteraction:','./whatsappInteraction.events','save'];(function(_0x519e9e,_0x564a7f){var _0x3b1d21=function(_0x1ce20c){while(--_0x1ce20c){_0x519e9e['push'](_0x519e9e['shift']());}};_0x3b1d21(++_0x564a7f);}(_0x15d2,0x101));var _0x215d=function(_0x21aec3,_0x5c97e9){_0x21aec3=_0x21aec3-0x0;var _0x288bbc=_0x15d2[_0x21aec3];return _0x288bbc;};'use strict';var WhatsappInteractionEvents=require(_0x215d('0x0'));var events=[_0x215d('0x1'),'remove',_0x215d('0x2')];function createListener(_0x58cfbb,_0x21534b){return function(_0x4bb29d){_0x21534b[_0x215d('0x3')](_0x58cfbb,_0x4bb29d);};}function removeListener(_0x530268,_0x19359c){return function(){WhatsappInteractionEvents['removeListener'](_0x530268,_0x19359c);};}exports[_0x215d('0x4')]=function(_0x40b8ec){for(var _0x2aeff5=0x0,_0x3062ae=events[_0x215d('0x5')];_0x2aeff5<_0x3062ae;_0x2aeff5++){var _0x14075=events[_0x2aeff5];var _0x3e0a81=createListener(_0x215d('0x6')+_0x14075,_0x40b8ec);WhatsappInteractionEvents['on'](_0x14075,_0x3e0a81);}};