f3d721230ad22b465640417656430896890b1cde
[motion2.git] / server / api / voicePrefix / voicePrefix.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 _0x3df4=['emit','register','voicePrefix:','remove','update'];(function(_0x506f52,_0x465874){var _0x34f19a=function(_0x2e8872){while(--_0x2e8872){_0x506f52['push'](_0x506f52['shift']());}};_0x34f19a(++_0x465874);}(_0x3df4,0x102));var _0x43df=function(_0xa1348,_0x2ca465){_0xa1348=_0xa1348-0x0;var _0x482ff5=_0x3df4[_0xa1348];return _0x482ff5;};'use strict';var VoicePrefixEvents=require('./voicePrefix.events');var events=['save',_0x43df('0x0'),_0x43df('0x1')];function createListener(_0x40bf18,_0x206707){return function(_0x38a050){_0x206707[_0x43df('0x2')](_0x40bf18,_0x38a050);};}function removeListener(_0x4297f4,_0x5affd4){return function(){VoicePrefixEvents['removeListener'](_0x4297f4,_0x5affd4);};}exports[_0x43df('0x3')]=function(_0x3111bf){for(var _0x3af1ec=0x0,_0x43fd8c=events['length'];_0x3af1ec<_0x43fd8c;_0x3af1ec++){var _0x5863be=events[_0x3af1ec];var _0x2492a9=createListener(_0x43df('0x4')+_0x5863be,_0x3111bf);VoicePrefixEvents['on'](_0x5863be,_0x2492a9);}};