Built motion from commit (unavailable).|2.5.21
[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 _0x09cb=['register','./plugin.events','update','emit'];(function(_0x3b65b4,_0x3282bd){var _0x33ff4a=function(_0xd88a93){while(--_0xd88a93){_0x3b65b4['push'](_0x3b65b4['shift']());}};_0x33ff4a(++_0x3282bd);}(_0x09cb,0xdd));var _0xb09c=function(_0x27d590,_0x337396){_0x27d590=_0x27d590-0x0;var _0x51d5f0=_0x09cb[_0x27d590];return _0x51d5f0;};'use strict';var PluginEvents=require(_0xb09c('0x0'));var events=['save','remove',_0xb09c('0x1')];function createListener(_0x235568,_0x12bf1c){return function(_0x31492c){_0x12bf1c[_0xb09c('0x2')](_0x235568,_0x31492c);};}function removeListener(_0x48ff24,_0x5a4f37){return function(){PluginEvents['removeListener'](_0x48ff24,_0x5a4f37);};}exports[_0xb09c('0x3')]=function(_0x57a2aa){for(var _0x3342e1=0x0,_0x249b28=events['length'];_0x3342e1<_0x249b28;_0x3342e1++){var _0x5770f0=events[_0x3342e1];var _0x4eb509=createListener('plugin:'+_0x5770f0,_0x57a2aa);PluginEvents['on'](_0x5770f0,_0x4eb509);}};