cedbb91cdee402393381d2e0b9330dff19a19498
[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 _0xbfa6=['register','length','./voicePrefix.events','save','emit','removeListener'];(function(_0xa81bc3,_0x2376a0){var _0x26f847=function(_0x182e63){while(--_0x182e63){_0xa81bc3['push'](_0xa81bc3['shift']());}};_0x26f847(++_0x2376a0);}(_0xbfa6,0x1d0));var _0x6bfa=function(_0x35468d,_0x2a7240){_0x35468d=_0x35468d-0x0;var _0x30da52=_0xbfa6[_0x35468d];return _0x30da52;};'use strict';var VoicePrefixEvents=require(_0x6bfa('0x0'));var events=[_0x6bfa('0x1'),'remove','update'];function createListener(_0x58e46d,_0x2cae45){return function(_0x10c0e2){_0x2cae45[_0x6bfa('0x2')](_0x58e46d,_0x10c0e2);};}function removeListener(_0x5eaacf,_0x3f77fa){return function(){VoicePrefixEvents[_0x6bfa('0x3')](_0x5eaacf,_0x3f77fa);};}exports[_0x6bfa('0x4')]=function(_0x39d9a3){for(var _0x3a3a1a=0x0,_0x41708e=events[_0x6bfa('0x5')];_0x3a3a1a<_0x41708e;_0x3a3a1a++){var _0x5b4337=events[_0x3a3a1a];var _0x1ad59f=createListener('voicePrefix:'+_0x5b4337,_0x39d9a3);VoicePrefixEvents['on'](_0x5b4337,_0x1ad59f);}};