Built motion from commit da617fac.|2.6.6
[motion2.git] / server / api / user-setting / user-setting.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 _0xbac2=['length','user-setting:','./user-setting.events','save','update','emit','user-setting:update:user-','UserId','register'];(function(_0x351eb8,_0x1fe60e){var _0xca7eec=function(_0xcf7c0f){while(--_0xcf7c0f){_0x351eb8['push'](_0x351eb8['shift']());}};_0xca7eec(++_0x1fe60e);}(_0xbac2,0x107));var _0x2bac=function(_0x37e886,_0x17d0ad){_0x37e886=_0x37e886-0x0;var _0x57c5cd=_0xbac2[_0x37e886];return _0x57c5cd;};'use strict';var UserSettingEvents=require(_0x2bac('0x0'));var events=[_0x2bac('0x1'),'remove',_0x2bac('0x2')];function createListener(_0x409c7b,_0x438e82){return function(_0x3bfb63){_0x438e82[_0x2bac('0x3')](_0x409c7b,_0x3bfb63);if(_0x409c7b==='user-setting:update'){_0x438e82[_0x2bac('0x3')](_0x2bac('0x4')+_0x3bfb63[_0x2bac('0x5')],_0x3bfb63);}};}exports[_0x2bac('0x6')]=function(_0x389c8e){for(var _0x4dde50=0x0,_0x190b40=events[_0x2bac('0x7')];_0x4dde50<_0x190b40;_0x4dde50++){var _0x242aa8=events[_0x4dde50];var _0x198335=createListener(_0x2bac('0x8')+_0x242aa8,_0x389c8e);UserSettingEvents['on'](_0x242aa8,_0x198335);}};