Built motion from commit 67e5df37.|2.0.66
[motion2.git] / server / api / chatInteraction / chatInteraction.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 _0x4173=['update','removeListener','length','./chatInteraction.events'];(function(_0x39234a,_0x1f8bef){var _0x2e80fa=function(_0x535ec3){while(--_0x535ec3){_0x39234a['push'](_0x39234a['shift']());}};_0x2e80fa(++_0x1f8bef);}(_0x4173,0x18b));var _0x3417=function(_0x4fc461,_0x566c03){_0x4fc461=_0x4fc461-0x0;var _0x1b0133=_0x4173[_0x4fc461];return _0x1b0133;};'use strict';var ChatInteractionEvents=require(_0x3417('0x0'));var events=['save','remove',_0x3417('0x1')];function createListener(_0x243351,_0x3e1f1b){return function(_0x395d89){_0x3e1f1b['emit'](_0x243351,_0x395d89);};}function removeListener(_0x57ac6b,_0x4aada0){return function(){ChatInteractionEvents[_0x3417('0x2')](_0x57ac6b,_0x4aada0);};}exports['register']=function(_0x42d0e1){for(var _0x1f3c3a=0x0,_0x150591=events[_0x3417('0x3')];_0x1f3c3a<_0x150591;_0x1f3c3a++){var _0x3ce8a5=events[_0x1f3c3a];var _0x1b0efe=createListener('chatInteraction:'+_0x3ce8a5,_0x42d0e1);ChatInteractionEvents['on'](_0x3ce8a5,_0x1b0efe);}};