Built motion from commit 1fa89557.|2.6.10
[motion2.git] / server / api / mailAccount / mailAccount.model.js
index 0279903..87e4ab6 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xf2ba=['secure','modernAuthentication','CloudProvider','auth','user','pass','./mailAccount.attributes','exports','MailAccount','mail_accounts','provider','custom','service','host','Smtp','port'];(function(_0x39bc4a,_0x595147){var _0x436b0d=function(_0x44e6eb){while(--_0x44e6eb){_0x39bc4a['push'](_0x39bc4a['shift']());}};_0x436b0d(++_0x595147);}(_0xf2ba,0x106));var _0xaf2b=function(_0x6148ee,_0x4d2fca){_0x6148ee=_0x6148ee-0x0;var _0x5afc74=_0xf2ba[_0x6148ee];return _0x5afc74;};'use strict';var attributes=require(_0xaf2b('0x0'));module[_0xaf2b('0x1')]=function(_0x24cce4){return _0x24cce4['define'](_0xaf2b('0x2'),attributes,{'tableName':_0xaf2b('0x3'),'paranoid':![],'indexes':[],'timestamps':!![],'instanceMethods':{'getSmtpOptions':function(){var _0x52ffa6=this;var _0x60e7d5={'id':_0x52ffa6['id'],'tls':{'rejectUnauthorized':![]}};if(_0x52ffa6[_0xaf2b('0x4')]!==_0xaf2b('0x5')){_0x60e7d5[_0xaf2b('0x6')]=_0x52ffa6[_0xaf2b('0x4')];}else{_0x60e7d5[_0xaf2b('0x7')]=_0x52ffa6[_0xaf2b('0x8')][_0xaf2b('0x7')];_0x60e7d5[_0xaf2b('0x9')]=_0x52ffa6['Smtp'][_0xaf2b('0x9')];_0x60e7d5[_0xaf2b('0xa')]=_0x52ffa6[_0xaf2b('0x8')][_0xaf2b('0xa')];}if(_0x52ffa6[_0xaf2b('0x8')]['authentication']){if(_0x52ffa6[_0xaf2b('0x8')][_0xaf2b('0xb')]){if(!_0x52ffa6['Smtp'][_0xaf2b('0xc')])throw new Error('Cloud\x20Provider\x20configuration\x20not\x20found');_0x60e7d5[_0xaf2b('0xd')]={'type':'OAuth2','user':_0x52ffa6['Smtp'][_0xaf2b('0xe')],'accessToken':_0x52ffa6['Smtp'][_0xaf2b('0xc')]['data5']};}else{_0x60e7d5[_0xaf2b('0xd')]={'user':_0x52ffa6[_0xaf2b('0x8')][_0xaf2b('0xe')],'pass':_0x52ffa6[_0xaf2b('0x8')][_0xaf2b('0xf')]};}}return _0x60e7d5;}}});};
\ No newline at end of file
+var _0x5199=['host','port','Smtp','secure','authentication','CloudProvider','Cloud\x20Provider\x20configuration\x20not\x20found','auth','OAuth2','user','./mailAccount.attributes','mail_accounts','custom','provider'];(function(_0x169f6c,_0x28ca7b){var _0x39247f=function(_0x22a9ee){while(--_0x22a9ee){_0x169f6c['push'](_0x169f6c['shift']());}};_0x39247f(++_0x28ca7b);}(_0x5199,0x1e6));var _0x9519=function(_0x487b0c,_0x14ff74){_0x487b0c=_0x487b0c-0x0;var _0x1adbdc=_0x5199[_0x487b0c];return _0x1adbdc;};'use strict';var attributes=require(_0x9519('0x0'));module['exports']=function(_0x2afc06){return _0x2afc06['define']('MailAccount',attributes,{'tableName':_0x9519('0x1'),'paranoid':![],'indexes':[],'timestamps':!![],'instanceMethods':{'getSmtpOptions':function(){var _0x591f73=this;var _0x2afd5c={'id':_0x591f73['id'],'tls':{'rejectUnauthorized':![]}};if(_0x591f73['provider']!==_0x9519('0x2')){_0x2afd5c['service']=_0x591f73[_0x9519('0x3')];}else{_0x2afd5c[_0x9519('0x4')]=_0x591f73['Smtp'][_0x9519('0x4')];_0x2afd5c[_0x9519('0x5')]=_0x591f73[_0x9519('0x6')][_0x9519('0x5')];_0x2afd5c[_0x9519('0x7')]=_0x591f73['Smtp'][_0x9519('0x7')];}if(_0x591f73[_0x9519('0x6')][_0x9519('0x8')]){if(_0x591f73['Smtp']['modernAuthentication']){if(!_0x591f73[_0x9519('0x6')][_0x9519('0x9')])throw new Error(_0x9519('0xa'));_0x2afd5c[_0x9519('0xb')]={'type':_0x9519('0xc'),'user':_0x591f73[_0x9519('0x6')][_0x9519('0xd')],'accessToken':_0x591f73['Smtp']['CloudProvider']['data5']};}else{_0x2afd5c[_0x9519('0xb')]={'user':_0x591f73[_0x9519('0x6')][_0x9519('0xd')],'pass':_0x591f73[_0x9519('0x6')]['pass']};}}return _0x2afd5c;}}});};
\ No newline at end of file