410e93175afcd8a894870932180025575c968603
[motion2.git] / server / api / chatInteraction / chatInteraction.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 _0x6959=['remove','update','register','length','save'];(function(_0x46e4cd,_0x10a676){var _0x35f64a=function(_0x14125b){while(--_0x14125b){_0x46e4cd['push'](_0x46e4cd['shift']());}};_0x35f64a(++_0x10a676);}(_0x6959,0x9a));var _0x9695=function(_0x20a584,_0xe384a5){_0x20a584=_0x20a584-0x0;var _0x4b41a8=_0x6959[_0x20a584];return _0x4b41a8;};'use strict';var ChatInteractionEvents=require('./chatInteraction.events');var events=[_0x9695('0x0'),_0x9695('0x1'),_0x9695('0x2')];function createListener(_0x541062,_0x33e595){return function(_0x2cf25c){_0x33e595['emit'](_0x541062,_0x2cf25c);};}function removeListener(_0x17f7dd,_0x4eb47b){return function(){ChatInteractionEvents['removeListener'](_0x17f7dd,_0x4eb47b);};}exports[_0x9695('0x3')]=function(_0x373e36){for(var _0x271062=0x0,_0x5668c7=events[_0x9695('0x4')];_0x271062<_0x5668c7;_0x271062++){var _0x82812e=events[_0x271062];var _0x363be5=createListener('chatInteraction:'+_0x82812e,_0x373e36);ChatInteractionEvents['on'](_0x82812e,_0x363be5);}};