Built motion from commit d5e4af8c.|2.6.23
[motion2.git] / server / api / intZohoConfiguration / intZohoConfiguration.rpc.js
index 37146c0..52447ee 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x59ed=['error','message','ZohoConfiguration,\x20%s,\x20%s','result','util','moment','bluebird','../../mysqldb','../../config/utils','../../config/logger','jayson/promise','client','http','request','then','info','request\x20sent','debug','ZohoConfiguration,\x20%s,\x20%s,\x20%s','stringify'];(function(_0x2a8b00,_0x953217){var _0x247a96=function(_0x47125e){while(--_0x47125e){_0x2a8b00['push'](_0x2a8b00['shift']());}};_0x247a96(++_0x953217);}(_0x59ed,0xf4));var _0xd59e=function(_0x1c36a8,_0x49c835){_0x1c36a8=_0x1c36a8-0x0;var _0xb622c5=_0x59ed[_0x1c36a8];return _0xb622c5;};'use strict';var _=require('lodash');var util=require(_0xd59e('0x0'));var moment=require(_0xd59e('0x1'));var BPromise=require(_0xd59e('0x2'));var rs=require('randomstring');var fs=require('fs');var Redis=require('ioredis');var db=require(_0xd59e('0x3'))['db'];var utils=require(_0xd59e('0x4'));var logger=require(_0xd59e('0x5'))('rpc');var config=require('../../config/environment');var jayson=require(_0xd59e('0x6'));var client=jayson[_0xd59e('0x7')][_0xd59e('0x8')]({'port':0x232a});function respondWithRpcPromise(_0x212319,_0x3ee5c3,_0x4ed46e){return new BPromise(function(_0x2e4511,_0x5b2660){return client[_0xd59e('0x9')](_0x212319,_0x4ed46e)[_0xd59e('0xa')](function(_0x4285ab){logger[_0xd59e('0xb')]('ZohoConfiguration,\x20%s,\x20%s',_0x3ee5c3,_0xd59e('0xc'));logger[_0xd59e('0xd')](_0xd59e('0xe'),_0x3ee5c3,_0xd59e('0xc'),JSON[_0xd59e('0xf')](_0x4285ab));if(_0x4285ab[_0xd59e('0x10')]){if(_0x4285ab[_0xd59e('0x10')]['code']===0x1f4){logger[_0xd59e('0x10')]('ZohoConfiguration,\x20%s,\x20%s',_0x3ee5c3,_0x4285ab['error']['message']);return _0x5b2660(_0x4285ab[_0xd59e('0x10')][_0xd59e('0x11')]);}logger[_0xd59e('0x10')](_0xd59e('0x12'),_0x3ee5c3,_0x4285ab[_0xd59e('0x10')][_0xd59e('0x11')]);return _0x2e4511(_0x4285ab[_0xd59e('0x10')][_0xd59e('0x11')]);}else{logger[_0xd59e('0xb')](_0xd59e('0x12'),_0x3ee5c3,_0xd59e('0xc'));_0x2e4511(_0x4285ab[_0xd59e('0x13')][_0xd59e('0x11')]);}})['catch'](function(_0x310bc4){logger[_0xd59e('0x10')](_0xd59e('0x12'),_0x3ee5c3,_0x310bc4);_0x5b2660(_0x310bc4);});});}
\ No newline at end of file
+var _0xefef=['error','info','result','lodash','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','../../config/environment','http','request','then','ZohoConfiguration,\x20%s,\x20%s','request\x20sent','ZohoConfiguration,\x20%s,\x20%s,\x20%s','stringify','message'];(function(_0x47a7d0,_0x4e182d){var _0xb9bd08=function(_0x588ee2){while(--_0x588ee2){_0x47a7d0['push'](_0x47a7d0['shift']());}};_0xb9bd08(++_0x4e182d);}(_0xefef,0xdf));var _0xfefe=function(_0x5c6994,_0x19ad9a){_0x5c6994=_0x5c6994-0x0;var _0x1d5c84=_0xefef[_0x5c6994];return _0x1d5c84;};'use strict';var _=require(_0xfefe('0x0'));var util=require('util');var moment=require(_0xfefe('0x1'));var BPromise=require(_0xfefe('0x2'));var rs=require(_0xfefe('0x3'));var fs=require('fs');var Redis=require(_0xfefe('0x4'));var db=require(_0xfefe('0x5'))['db'];var utils=require(_0xfefe('0x6'));var logger=require(_0xfefe('0x7'))('rpc');var config=require(_0xfefe('0x8'));var jayson=require('jayson/promise');var client=jayson['client'][_0xfefe('0x9')]({'port':0x232a});function respondWithRpcPromise(_0x18730b,_0x5e80b9,_0x338c93){return new BPromise(function(_0xfbf67e,_0xf1aa5b){return client[_0xfefe('0xa')](_0x18730b,_0x338c93)[_0xfefe('0xb')](function(_0x4472f1){logger['info'](_0xfefe('0xc'),_0x5e80b9,_0xfefe('0xd'));logger['debug'](_0xfefe('0xe'),_0x5e80b9,_0xfefe('0xd'),JSON[_0xfefe('0xf')](_0x4472f1));if(_0x4472f1['error']){if(_0x4472f1['error']['code']===0x1f4){logger['error'](_0xfefe('0xc'),_0x5e80b9,_0x4472f1['error'][_0xfefe('0x10')]);return _0xf1aa5b(_0x4472f1[_0xfefe('0x11')][_0xfefe('0x10')]);}logger[_0xfefe('0x11')](_0xfefe('0xc'),_0x5e80b9,_0x4472f1[_0xfefe('0x11')][_0xfefe('0x10')]);return _0xfbf67e(_0x4472f1[_0xfefe('0x11')][_0xfefe('0x10')]);}else{logger[_0xfefe('0x12')]('ZohoConfiguration,\x20%s,\x20%s',_0x5e80b9,_0xfefe('0xd'));_0xfbf67e(_0x4472f1[_0xfefe('0x13')][_0xfefe('0x10')]);}})['catch'](function(_0x24353f){logger['error'](_0xfefe('0xc'),_0x5e80b9,_0x24353f);_0xf1aa5b(_0x24353f);});});}
\ No newline at end of file