Built motion from commit (unavailable).|2.5.6
[motion2.git] / server / api / plugin / plugin.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 _0x9e6b=['register','length','./plugin.events','save','update','emit'];(function(_0x5c5255,_0x54b3e1){var _0x413a01=function(_0x4b915a){while(--_0x4b915a){_0x5c5255['push'](_0x5c5255['shift']());}};_0x413a01(++_0x54b3e1);}(_0x9e6b,0x11c));var _0xb9e6=function(_0x2641f9,_0x26715f){_0x2641f9=_0x2641f9-0x0;var _0x585741=_0x9e6b[_0x2641f9];return _0x585741;};'use strict';var PluginEvents=require(_0xb9e6('0x0'));var events=[_0xb9e6('0x1'),'remove',_0xb9e6('0x2')];function createListener(_0x54a988,_0x5ab0d0){return function(_0x33d064){_0x5ab0d0[_0xb9e6('0x3')](_0x54a988,_0x33d064);};}function removeListener(_0xb74c07,_0x214661){return function(){PluginEvents['removeListener'](_0xb74c07,_0x214661);};}exports[_0xb9e6('0x4')]=function(_0x1a6a4f){for(var _0x1b9eed=0x0,_0x4bb674=events[_0xb9e6('0x5')];_0x1b9eed<_0x4bb674;_0x1b9eed++){var _0x49565c=events[_0x1b9eed];var _0x5a54db=createListener('plugin:'+_0x49565c,_0x1a6a4f);PluginEvents['on'](_0x49565c,_0x5a54db);}};