Built motion from commit 5b761a7b.|2.5.36
[motion2.git] / server / api / mailQueue / mailQueue.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 _0xd139=['save','emit','removeListener','length','./mailQueue.events'];(function(_0x20a584,_0xe384a5){var _0x4b41a8=function(_0x2127c6){while(--_0x2127c6){_0x20a584['push'](_0x20a584['shift']());}};_0x4b41a8(++_0xe384a5);}(_0xd139,0x14e));var _0x9d13=function(_0x510201,_0x318624){_0x510201=_0x510201-0x0;var _0x2259d2=_0xd139[_0x510201];return _0x2259d2;};'use strict';var MailQueueEvents=require(_0x9d13('0x0'));var events=[_0x9d13('0x1'),'remove','update'];function createListener(_0x21fb63,_0x477215){return function(_0x3d392a){_0x477215[_0x9d13('0x2')](_0x21fb63,_0x3d392a);};}function removeListener(_0x1d39f0,_0xdeacf6){return function(){MailQueueEvents[_0x9d13('0x3')](_0x1d39f0,_0xdeacf6);};}exports['register']=function(_0x4c8e60){for(var _0x2918eb=0x0,_0x50294b=events[_0x9d13('0x4')];_0x2918eb<_0x50294b;_0x2918eb++){var _0x4b3db0=events[_0x2918eb];var _0x434ef6=createListener('mailQueue:'+_0x4b3db0,_0x4c8e60);MailQueueEvents['on'](_0x4b3db0,_0x434ef6);}};