Built motion from commit (unavailable).|2.5.18
[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 _0x7980=['emit','removeListener','length','./plugin.events','save','update'];(function(_0x3dd15e,_0x1f0015){var _0x231fd0=function(_0x4f680a){while(--_0x4f680a){_0x3dd15e['push'](_0x3dd15e['shift']());}};_0x231fd0(++_0x1f0015);}(_0x7980,0x123));var _0x0798=function(_0x2eedfa,_0xa6942c){_0x2eedfa=_0x2eedfa-0x0;var _0x38237c=_0x7980[_0x2eedfa];return _0x38237c;};'use strict';var PluginEvents=require(_0x0798('0x0'));var events=[_0x0798('0x1'),'remove',_0x0798('0x2')];function createListener(_0x2e807f,_0x2c2fe1){return function(_0x1c4c58){_0x2c2fe1[_0x0798('0x3')](_0x2e807f,_0x1c4c58);};}function removeListener(_0x43fa79,_0x119a23){return function(){PluginEvents[_0x0798('0x4')](_0x43fa79,_0x119a23);};}exports['register']=function(_0x12ea59){for(var _0x22a15f=0x0,_0x429cea=events[_0x0798('0x5')];_0x22a15f<_0x429cea;_0x22a15f++){var _0x21b2e2=events[_0x22a15f];var _0x6d2904=createListener('plugin:'+_0x21b2e2,_0x12ea59);PluginEvents['on'](_0x21b2e2,_0x6d2904);}};