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 _0x6ff1=['length','mailInteraction:','emit'];(function(_0x16bb0e,_0x343132){var _0x102b8b=function(_0x17a62b){while(--_0x17a62b){_0x16bb0e['push'](_0x16bb0e['shift']());}};_0x102b8b(++_0x343132);}(_0x6ff1,0x107));var _0x16ff=function(_0x4c98fd,_0x37d454){_0x4c98fd=_0x4c98fd-0x0;var _0x227898=_0x6ff1[_0x4c98fd];return _0x227898;};'use strict';var MailInteractionEvents=require('./mailInteraction.events');var events=['save','remove','update'];function createListener(_0x9cf8bb,_0x58e76f){return function(_0x1605d1){_0x58e76f[_0x16ff('0x0')](_0x9cf8bb,_0x1605d1);};}function removeListener(_0x289cbc,_0x5f322e){return function(){MailInteractionEvents['removeListener'](_0x289cbc,_0x5f322e);};}exports['register']=function(_0x5013a8){for(var _0x236d8b=0x0,_0x52a63e=events[_0x16ff('0x1')];_0x236d8b<_0x52a63e;_0x236d8b++){var _0x45b378=events[_0x236d8b];var _0x1228fa=createListener(_0x16ff('0x2')+_0x45b378,_0x5013a8);MailInteractionEvents['on'](_0x45b378,_0x1228fa);}};