Built motion from commit (unavailable).|2.5.16
[motion2.git] / server / api / chatMessage / chatMessage.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 _0x4975=['length','./chatMessage.events','remove','update','emit','removeListener','register'];(function(_0x4b58ba,_0x5855ca){var _0x34ef9a=function(_0x39340d){while(--_0x39340d){_0x4b58ba['push'](_0x4b58ba['shift']());}};_0x34ef9a(++_0x5855ca);}(_0x4975,0x86));var _0x5497=function(_0x3ec31b,_0x61137a){_0x3ec31b=_0x3ec31b-0x0;var _0x5db7d4=_0x4975[_0x3ec31b];return _0x5db7d4;};'use strict';var ChatMessageEvents=require(_0x5497('0x0'));var events=['save',_0x5497('0x1'),_0x5497('0x2')];function createListener(_0xfc7927,_0x349f5f){return function(_0x135f6f){_0x349f5f[_0x5497('0x3')](_0xfc7927,_0x135f6f);};}function removeListener(_0x14cecb,_0xeb31af){return function(){ChatMessageEvents[_0x5497('0x4')](_0x14cecb,_0xeb31af);};}exports[_0x5497('0x5')]=function(_0x539a27){for(var _0x37e48d=0x0,_0x4f563d=events[_0x5497('0x6')];_0x37e48d<_0x4f563d;_0x37e48d++){var _0x674a2a=events[_0x37e48d];var _0x368e8b=createListener('chatMessage:'+_0x674a2a,_0x539a27);ChatMessageEvents['on'](_0x674a2a,_0x368e8b);}};