Built motion from commit (unavailable).|2.4.13
[motion2.git] / server / api / chatGroup / chatGroup.rpc.js
index 8b0d865..a937807 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x8b02=['util','randomstring','ioredis','../../mysqldb','../../config/utils','rpc','../../config/environment','client','http','redis','localhost','socket.io-emitter','./chatGroup.socket','register','request','then','ChatGroup,\x20%s,\x20%s','request\x20sent','ChatGroup,\x20%s,\x20%s,\x20%s','stringify','error','code','message','info','result','catch'];(function(_0x50f810,_0x24e067){var _0x13995a=function(_0x48bb1c){while(--_0x48bb1c){_0x50f810['push'](_0x50f810['shift']());}};_0x13995a(++_0x24e067);}(_0x8b02,0x1ee));var _0x28b0=function(_0x1780fb,_0xf933a4){_0x1780fb=_0x1780fb-0x0;var _0x2d1059=_0x8b02[_0x1780fb];return _0x2d1059;};'use strict';var _=require('lodash');var util=require(_0x28b0('0x0'));var moment=require('moment');var BPromise=require('bluebird');var rs=require(_0x28b0('0x1'));var fs=require('fs');var Redis=require(_0x28b0('0x2'));var db=require(_0x28b0('0x3'))['db'];var utils=require(_0x28b0('0x4'));var logger=require('../../config/logger')(_0x28b0('0x5'));var config=require(_0x28b0('0x6'));var jayson=require('jayson/promise');var client=jayson[_0x28b0('0x7')][_0x28b0('0x8')]({'port':0x232a});config[_0x28b0('0x9')]=_['defaults'](config[_0x28b0('0x9')],{'host':_0x28b0('0xa'),'port':0x18eb});var socket=require(_0x28b0('0xb'))(new Redis(config[_0x28b0('0x9')]));require(_0x28b0('0xc'))[_0x28b0('0xd')](socket);function respondWithRpcPromise(_0x50fd74,_0x5baf5a,_0x5033fb){return new BPromise(function(_0x49aeb5,_0x284398){return client[_0x28b0('0xe')](_0x50fd74,_0x5033fb)[_0x28b0('0xf')](function(_0xb8f16){logger['info'](_0x28b0('0x10'),_0x5baf5a,_0x28b0('0x11'));logger['debug'](_0x28b0('0x12'),_0x5baf5a,_0x28b0('0x11'),JSON[_0x28b0('0x13')](_0xb8f16));if(_0xb8f16['error']){if(_0xb8f16[_0x28b0('0x14')][_0x28b0('0x15')]===0x1f4){logger[_0x28b0('0x14')](_0x28b0('0x10'),_0x5baf5a,_0xb8f16['error'][_0x28b0('0x16')]);return _0x284398(_0xb8f16[_0x28b0('0x14')][_0x28b0('0x16')]);}logger[_0x28b0('0x14')](_0x28b0('0x10'),_0x5baf5a,_0xb8f16[_0x28b0('0x14')][_0x28b0('0x16')]);return _0x49aeb5(_0xb8f16[_0x28b0('0x14')]['message']);}else{logger[_0x28b0('0x17')](_0x28b0('0x10'),_0x5baf5a,_0x28b0('0x11'));_0x49aeb5(_0xb8f16[_0x28b0('0x18')][_0x28b0('0x16')]);}})[_0x28b0('0x19')](function(_0x42e825){logger[_0x28b0('0x14')]('ChatGroup,\x20%s,\x20%s',_0x5baf5a,_0x42e825);_0x284398(_0x42e825);});});}
\ No newline at end of file
+var _0xffcf=['socket.io-emitter','register','then','info','ChatGroup,\x20%s,\x20%s','request\x20sent','ChatGroup,\x20%s,\x20%s,\x20%s','stringify','error','code','message','result','catch','util','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','jayson/promise','client','http','redis','defaults','localhost'];(function(_0xd0b415,_0x149675){var _0x2bdf2c=function(_0x59fbfa){while(--_0x59fbfa){_0xd0b415['push'](_0xd0b415['shift']());}};_0x2bdf2c(++_0x149675);}(_0xffcf,0x141));var _0xfffc=function(_0x5783f4,_0x4a9e0a){_0x5783f4=_0x5783f4-0x0;var _0x28e380=_0xffcf[_0x5783f4];return _0x28e380;};'use strict';var _=require('lodash');var util=require(_0xfffc('0x0'));var moment=require(_0xfffc('0x1'));var BPromise=require(_0xfffc('0x2'));var rs=require(_0xfffc('0x3'));var fs=require('fs');var Redis=require(_0xfffc('0x4'));var db=require(_0xfffc('0x5'))['db'];var utils=require(_0xfffc('0x6'));var logger=require(_0xfffc('0x7'))(_0xfffc('0x8'));var config=require('../../config/environment');var jayson=require(_0xfffc('0x9'));var client=jayson[_0xfffc('0xa')][_0xfffc('0xb')]({'port':0x232a});config[_0xfffc('0xc')]=_[_0xfffc('0xd')](config[_0xfffc('0xc')],{'host':_0xfffc('0xe'),'port':0x18eb});var socket=require(_0xfffc('0xf'))(new Redis(config[_0xfffc('0xc')]));require('./chatGroup.socket')[_0xfffc('0x10')](socket);function respondWithRpcPromise(_0x18b0ed,_0x415ebb,_0x1be6ef){return new BPromise(function(_0x33d66e,_0x58eee0){return client['request'](_0x18b0ed,_0x1be6ef)[_0xfffc('0x11')](function(_0x350442){logger[_0xfffc('0x12')](_0xfffc('0x13'),_0x415ebb,_0xfffc('0x14'));logger['debug'](_0xfffc('0x15'),_0x415ebb,_0xfffc('0x14'),JSON[_0xfffc('0x16')](_0x350442));if(_0x350442['error']){if(_0x350442[_0xfffc('0x17')][_0xfffc('0x18')]===0x1f4){logger[_0xfffc('0x17')](_0xfffc('0x13'),_0x415ebb,_0x350442[_0xfffc('0x17')][_0xfffc('0x19')]);return _0x58eee0(_0x350442[_0xfffc('0x17')][_0xfffc('0x19')]);}logger[_0xfffc('0x17')](_0xfffc('0x13'),_0x415ebb,_0x350442[_0xfffc('0x17')]['message']);return _0x33d66e(_0x350442[_0xfffc('0x17')]['message']);}else{logger[_0xfffc('0x12')](_0xfffc('0x13'),_0x415ebb,'request\x20sent');_0x33d66e(_0x350442[_0xfffc('0x1a')]['message']);}})[_0xfffc('0x1b')](function(_0x2417ab){logger['error'](_0xfffc('0x13'),_0x415ebb,_0x2417ab);_0x58eee0(_0x2417ab);});});}
\ No newline at end of file