ed020817957393f6e32497bd58c1c54a5c61a67f
[motion2.git] / server / api / user / user.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 _0x76ae=['emit','register','length','user:','./user.events','save','update'];(function(_0x6efcec,_0x14727b){var _0x233e99=function(_0x128468){while(--_0x128468){_0x6efcec['push'](_0x6efcec['shift']());}};_0x233e99(++_0x14727b);}(_0x76ae,0x17e));var _0xe76a=function(_0x567097,_0x345516){_0x567097=_0x567097-0x0;var _0x5e84f8=_0x76ae[_0x567097];return _0x5e84f8;};'use strict';var UserEvents=require(_0xe76a('0x0'));var events=[_0xe76a('0x1'),'remove',_0xe76a('0x2')];function createListener(_0x5620c3,_0x45bb80){return function(_0x414d25){_0x45bb80[_0xe76a('0x3')](_0x5620c3,_0x414d25);};}function removeListener(_0x328ce1,_0x2fb319){return function(){UserEvents['removeListener'](_0x328ce1,_0x2fb319);};}exports[_0xe76a('0x4')]=function(_0x4ea491){for(var _0x1f79b6=0x0,_0x3242d4=events[_0xe76a('0x5')];_0x1f79b6<_0x3242d4;_0x1f79b6++){var _0x236850=events[_0x1f79b6];var _0xcd20aa=createListener(_0xe76a('0x6')+_0x236850,_0x4ea491);UserEvents['on'](_0x236850,_0xcd20aa);}};