Built motion from commit 97153652.|2.6.26
[motion2.git] / server / api / team / team.rpc.js
index 28b5b2c..57ecb47 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0x6718=['Team,\x20%s,\x20%s,\x20%s','stringify','error','code','message','result','lodash','moment','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','redis','defaults','localhost','socket.io-emitter','./team.socket','request','info','Team,\x20%s,\x20%s','request\x20sent'];(function(_0x79a6e8,_0x1c2b24){var _0xeeb993=function(_0x9ed95e){while(--_0x9ed95e){_0x79a6e8['push'](_0x79a6e8['shift']());}};_0xeeb993(++_0x1c2b24);}(_0x6718,0xec));var _0x8671=function(_0x6148ee,_0x4d2fca){_0x6148ee=_0x6148ee-0x0;var _0x5afc74=_0x6718[_0x6148ee];return _0x5afc74;};'use strict';var _=require(_0x8671('0x0'));var util=require('util');var moment=require(_0x8671('0x1'));var BPromise=require('bluebird');var rs=require(_0x8671('0x2'));var fs=require('fs');var Redis=require(_0x8671('0x3'));var db=require(_0x8671('0x4'))['db'];var utils=require(_0x8671('0x5'));var logger=require(_0x8671('0x6'))(_0x8671('0x7'));var config=require('../../config/environment');var jayson=require('jayson/promise');var client=jayson['client']['http']({'port':0x232a});config[_0x8671('0x8')]=_[_0x8671('0x9')](config[_0x8671('0x8')],{'host':_0x8671('0xa'),'port':0x18eb});var socket=require(_0x8671('0xb'))(new Redis(config[_0x8671('0x8')]));require(_0x8671('0xc'))['register'](socket);function respondWithRpcPromise(_0x1f63ee,_0x2ab0a1,_0x381ce2){return new BPromise(function(_0x4aa748,_0x340491){return client[_0x8671('0xd')](_0x1f63ee,_0x381ce2)['then'](function(_0x3434e3){logger[_0x8671('0xe')](_0x8671('0xf'),_0x2ab0a1,_0x8671('0x10'));logger['debug'](_0x8671('0x11'),_0x2ab0a1,_0x8671('0x10'),JSON[_0x8671('0x12')](_0x3434e3));if(_0x3434e3[_0x8671('0x13')]){if(_0x3434e3[_0x8671('0x13')][_0x8671('0x14')]===0x1f4){logger[_0x8671('0x13')](_0x8671('0xf'),_0x2ab0a1,_0x3434e3[_0x8671('0x13')][_0x8671('0x15')]);return _0x340491(_0x3434e3[_0x8671('0x13')]['message']);}logger[_0x8671('0x13')]('Team,\x20%s,\x20%s',_0x2ab0a1,_0x3434e3[_0x8671('0x13')]['message']);return _0x4aa748(_0x3434e3['error'][_0x8671('0x15')]);}else{logger[_0x8671('0xe')]('Team,\x20%s,\x20%s',_0x2ab0a1,_0x8671('0x10'));_0x4aa748(_0x3434e3[_0x8671('0x16')][_0x8671('0x15')]);}})['catch'](function(_0xb3937e){logger[_0x8671('0x13')]('Team,\x20%s,\x20%s',_0x2ab0a1,_0xb3937e);_0x340491(_0xb3937e);});});}
\ No newline at end of file
+var _0xf2d7=['redis','localhost','socket.io-emitter','register','then','info','request\x20sent','debug','stringify','error','code','Team,\x20%s,\x20%s','message','result','catch','lodash','util','moment','bluebird','randomstring','ioredis','../../mysqldb','../../config/utils','../../config/logger','rpc','../../config/environment','jayson/promise','client'];(function(_0x340fc7,_0x12a901){var _0x586c93=function(_0xc3a679){while(--_0xc3a679){_0x340fc7['push'](_0x340fc7['shift']());}};_0x586c93(++_0x12a901);}(_0xf2d7,0xd3));var _0x7f2d=function(_0x26aed4,_0x2ee229){_0x26aed4=_0x26aed4-0x0;var _0x10d095=_0xf2d7[_0x26aed4];return _0x10d095;};'use strict';var _=require(_0x7f2d('0x0'));var util=require(_0x7f2d('0x1'));var moment=require(_0x7f2d('0x2'));var BPromise=require(_0x7f2d('0x3'));var rs=require(_0x7f2d('0x4'));var fs=require('fs');var Redis=require(_0x7f2d('0x5'));var db=require(_0x7f2d('0x6'))['db'];var utils=require(_0x7f2d('0x7'));var logger=require(_0x7f2d('0x8'))(_0x7f2d('0x9'));var config=require(_0x7f2d('0xa'));var jayson=require(_0x7f2d('0xb'));var client=jayson[_0x7f2d('0xc')]['http']({'port':0x232a});config[_0x7f2d('0xd')]=_['defaults'](config[_0x7f2d('0xd')],{'host':_0x7f2d('0xe'),'port':0x18eb});var socket=require(_0x7f2d('0xf'))(new Redis(config['redis']));require('./team.socket')[_0x7f2d('0x10')](socket);function respondWithRpcPromise(_0x3bb0fc,_0x36f540,_0x205de2){return new BPromise(function(_0x5157cb,_0x4577de){return client['request'](_0x3bb0fc,_0x205de2)[_0x7f2d('0x11')](function(_0x300a5d){logger[_0x7f2d('0x12')]('Team,\x20%s,\x20%s',_0x36f540,_0x7f2d('0x13'));logger[_0x7f2d('0x14')]('Team,\x20%s,\x20%s,\x20%s',_0x36f540,_0x7f2d('0x13'),JSON[_0x7f2d('0x15')](_0x300a5d));if(_0x300a5d[_0x7f2d('0x16')]){if(_0x300a5d[_0x7f2d('0x16')][_0x7f2d('0x17')]===0x1f4){logger[_0x7f2d('0x16')](_0x7f2d('0x18'),_0x36f540,_0x300a5d['error'][_0x7f2d('0x19')]);return _0x4577de(_0x300a5d[_0x7f2d('0x16')][_0x7f2d('0x19')]);}logger[_0x7f2d('0x16')]('Team,\x20%s,\x20%s',_0x36f540,_0x300a5d['error'][_0x7f2d('0x19')]);return _0x5157cb(_0x300a5d[_0x7f2d('0x16')][_0x7f2d('0x19')]);}else{logger[_0x7f2d('0x12')]('Team,\x20%s,\x20%s',_0x36f540,'request\x20sent');_0x5157cb(_0x300a5d[_0x7f2d('0x1a')][_0x7f2d('0x19')]);}})[_0x7f2d('0x1b')](function(_0x15dd90){logger[_0x7f2d('0x16')](_0x7f2d('0x18'),_0x36f540,_0x15dd90);_0x4577de(_0x15dd90);});});}
\ No newline at end of file