1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
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. *
17 // *************************************************************************
18 var _0xa780=['MailSubstatus','setMaxListeners','update','emit','hasOwnProperty','hook','exports','events','../../mysqldb'];(function(_0x4a619d,_0x187915){var _0x3b7e33=function(_0x543a5d){while(--_0x543a5d){_0x4a619d['push'](_0x4a619d['shift']());}};_0x3b7e33(++_0x187915);}(_0xa780,0x103));var _0x0a78=function(_0x30a8b8,_0x1643a4){_0x30a8b8=_0x30a8b8-0x0;var _0x2f5a12=_0xa780[_0x30a8b8];return _0x2f5a12;};'use strict';var EventEmitter=require(_0x0a78('0x0'));var MailSubstatus=require(_0x0a78('0x1'))['db'][_0x0a78('0x2')];var MailSubstatusEvents=new EventEmitter();MailSubstatusEvents[_0x0a78('0x3')](0x0);var events={'afterUpdate':_0x0a78('0x4')};function emitEvent(_0x500c69){return function(_0x16a9e5,_0x3d4bdf,_0x2d77a8){MailSubstatusEvents[_0x0a78('0x5')](_0x500c69+':'+_0x16a9e5['id'],_0x16a9e5);MailSubstatusEvents['emit'](_0x500c69,_0x16a9e5);_0x2d77a8(null);};}for(var e in events){if(events[_0x0a78('0x6')](e)){var event=events[e];MailSubstatus[_0x0a78('0x7')](e,emitEvent(event));}}module[_0x0a78('0x8')]=MailSubstatusEvents;