Built motion from commit 85328c08.|2.5.50
[motion2.git] / server / api / team / team.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 _0x7c35=['emit','register','length','save','remove','update'];(function(_0x51eab8,_0x39bc64){var _0x166961=function(_0x2ae9e6){while(--_0x2ae9e6){_0x51eab8['push'](_0x51eab8['shift']());}};_0x166961(++_0x39bc64);}(_0x7c35,0x135));var _0x57c3=function(_0x4cdcb0,_0x2a66f7){_0x4cdcb0=_0x4cdcb0-0x0;var _0x1df0b0=_0x7c35[_0x4cdcb0];return _0x1df0b0;};'use strict';var TeamEvents=require('./team.events');var events=[_0x57c3('0x0'),_0x57c3('0x1'),_0x57c3('0x2')];function createListener(_0x14b13b,_0x23e38f){return function(_0x2acb85){_0x23e38f[_0x57c3('0x3')](_0x14b13b,_0x2acb85);};}function removeListener(_0x5519f2,_0x1ebc41){return function(){TeamEvents['removeListener'](_0x5519f2,_0x1ebc41);};}exports[_0x57c3('0x4')]=function(_0x562f00){for(var _0x564573=0x0,_0x341f1=events[_0x57c3('0x5')];_0x564573<_0x341f1;_0x564573++){var _0x38de37=events[_0x564573];var _0x13cf86=createListener('team:'+_0x38de37,_0x562f00);TeamEvents['on'](_0x38de37,_0x13cf86);}};