Built motion from commit 953226e6.|2.6.32
[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 _0x111c=['./whatsappInteraction.events','save','register','length','whatsappInteraction:'];(function(_0x17928f,_0x4ad33f){var _0x500b63=function(_0x127644){while(--_0x127644){_0x17928f['push'](_0x17928f['shift']());}};_0x500b63(++_0x4ad33f);}(_0x111c,0xb4));var _0xc111=function(_0x501510,_0x61caa9){_0x501510=_0x501510-0x0;var _0x1e6ee5=_0x111c[_0x501510];return _0x1e6ee5;};'use strict';var WhatsappInteractionEvents=require(_0xc111('0x0'));var events=[_0xc111('0x1'),'remove','update'];function createListener(_0x17a79a,_0x47534e){return function(_0x1833e2){_0x47534e['emit'](_0x17a79a,_0x1833e2);};}function removeListener(_0x1969c5,_0x417f4c){return function(){WhatsappInteractionEvents['removeListener'](_0x1969c5,_0x417f4c);};}exports[_0xc111('0x2')]=function(_0x1a5ef){for(var _0x53d87e=0x0,_0x1139f4=events[_0xc111('0x3')];_0x53d87e<_0x1139f4;_0x53d87e++){var _0x381f7f=events[_0x53d87e];var _0x43b7a9=createListener(_0xc111('0x4')+_0x381f7f,_0x1a5ef);WhatsappInteractionEvents['on'](_0x381f7f,_0x43b7a9);}};