Built motion from commit df3e9871f6bcc3432fec345b2f4facbd4dba8b5c. Version 3.0.0...
[motion-next.git] / server / api / chatInteraction / chatInteraction.rpc.js
index 314e36f..e535bcb 100644 (file)
@@ -1 +1 @@
-const a69_0x2c27=['info','then','options','body','debug','AddTags','raw','../../mysqldb','where','AddTagsToChatInteraction','message','update','catch','ids','limit','lodash','addTags','ChatInteraction','UpdateChatInteraction','error','stringify','attributes','findOne','../../config/logger'];(function(_0x11698b,_0x2c27d9){const _0x11beb6=function(_0x5a41ec){while(--_0x5a41ec){_0x11698b['push'](_0x11698b['shift']());}};_0x11beb6(++_0x2c27d9);}(a69_0x2c27,0x15b));const a69_0x11be=function(_0x11698b,_0x2c27d9){_0x11698b=_0x11698b-0x0;let _0x11beb6=a69_0x2c27[_0x11698b];return _0x11beb6;};const _0x34d9bc=a69_0x11be;'use strict';const _=require(_0x34d9bc('0x4')),db=require(_0x34d9bc('0x14'))['db'],logger=require(_0x34d9bc('0xc'))('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require('./chatInteraction.socket')['register'](socket),exports['UpdateChatInteraction']=function(_0x5a41ec){const _0x252d34=this;return new Promise(function(_0x53a678,_0x384940){const _0x181112=a69_0x11be;return db['ChatInteraction'][_0x181112('0x0')](_0x5a41ec[_0x181112('0x10')],{'raw':_0x5a41ec[_0x181112('0xf')]?_0x5a41ec['options'][_0x181112('0x13')]===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0x5a41ec['options']?_0x5a41ec[_0x181112('0xf')][_0x181112('0x15')]||null:null,'attributes':_0x5a41ec[_0x181112('0xf')]?_0x5a41ec[_0x181112('0xf')][_0x181112('0xa')]||null:null,'limit':_0x5a41ec[_0x181112('0xf')]?_0x5a41ec[_0x181112('0xf')][_0x181112('0x3')]||null:null})[_0x181112('0xe')](function(_0x18e86f){const _0x4dba71=_0x181112;logger[_0x4dba71('0xd')](_0x4dba71('0x7'),_0x5a41ec),logger[_0x4dba71('0x11')](_0x4dba71('0x7'),_0x5a41ec,JSON[_0x4dba71('0x9')](_0x18e86f)),_0x53a678(_0x18e86f);})[_0x181112('0x1')](function(_0x130190){const _0x178cb0=_0x181112;logger[_0x178cb0('0x8')]('UpdateChatInteraction',_0x130190[_0x178cb0('0x17')],_0x5a41ec),_0x384940(_0x252d34[_0x178cb0('0x8')](0x1f4,_0x130190['message']));});});},exports[_0x34d9bc('0x16')]=function(_0x8352af){const _0x149c53=this;return new Promise(function(_0x4f3a8d,_0x4fea78){const _0x308f29=a69_0x11be;return db[_0x308f29('0x6')][_0x308f29('0xb')]({'where':_0x8352af['options']?_0x8352af[_0x308f29('0xf')][_0x308f29('0x15')]||null:null})[_0x308f29('0xe')](function(_0x297c9c){const _0xc842c0=_0x308f29;if(_0x297c9c)return _0x297c9c[_0xc842c0('0x5')](_0x8352af[_0xc842c0('0x10')][_0xc842c0('0x2')],{'through':_['omit'](_0x8352af[_0xc842c0('0x10')],[_0xc842c0('0x2'),'id'])});})['then'](function([_0x22d0f5]){const _0x1e7936=_0x308f29;logger['info']('AddTags',_0x8352af),logger[_0x1e7936('0x11')](_0x1e7936('0x12'),_0x8352af,JSON['stringify'](_0x22d0f5)),_0x4f3a8d(_0x22d0f5);})[_0x308f29('0x1')](function(_0x65a506){const _0xea6838=_0x308f29;logger['error'](_0xea6838('0x12'),_0x65a506[_0xea6838('0x17')],_0x8352af),_0x4fea78(_0x149c53[_0xea6838('0x8')](0x1f4,_0x65a506[_0xea6838('0x17')]));});});};
\ No newline at end of file
+const a69_0x19bd=['limit','lodash','../../config/logger','ids','info','where','attributes','error','register','AddTagsToChatInteraction','UpdateChatInteraction','body','catch','message','then','options','AddTags','update','../../mysqldb'];(function(_0x110d5a,_0x19bdea){const _0x34c5e3=function(_0xc86429){while(--_0xc86429){_0x110d5a['push'](_0x110d5a['shift']());}};_0x34c5e3(++_0x19bdea);}(a69_0x19bd,0x1e1));const a69_0x34c5=function(_0x110d5a,_0x19bdea){_0x110d5a=_0x110d5a-0x0;let _0x34c5e3=a69_0x19bd[_0x110d5a];return _0x34c5e3;};const _0xce8077=a69_0x34c5;'use strict';const _=require(_0xce8077('0xe')),db=require(_0xce8077('0xc'))['db'],logger=require(_0xce8077('0xf'))('rpc'),{getSocket}=require('../../rediscache'),socket=getSocket();require('./chatInteraction.socket')[_0xce8077('0x2')](socket),exports['UpdateChatInteraction']=function(_0xc86429){const _0x17160d=this;return new Promise(function(_0xd8119b,_0x2a5213){const _0x53e9cb=a69_0x34c5;return db['ChatInteraction'][_0x53e9cb('0xb')](_0xc86429['body'],{'raw':_0xc86429[_0x53e9cb('0x9')]?_0xc86429[_0x53e9cb('0x9')]['raw']===undefined?!![]:![]:!![],'individualHooks':!![],'where':_0xc86429[_0x53e9cb('0x9')]?_0xc86429[_0x53e9cb('0x9')][_0x53e9cb('0x12')]||null:null,'attributes':_0xc86429[_0x53e9cb('0x9')]?_0xc86429['options'][_0x53e9cb('0x0')]||null:null,'limit':_0xc86429[_0x53e9cb('0x9')]?_0xc86429[_0x53e9cb('0x9')][_0x53e9cb('0xd')]||null:null})['then'](function(_0x443f8a){const _0x7e8e09=_0x53e9cb;logger[_0x7e8e09('0x11')]('UpdateChatInteraction',_0xc86429),logger['debug'](_0x7e8e09('0x4'),_0xc86429,JSON['stringify'](_0x443f8a)),_0xd8119b(_0x443f8a);})[_0x53e9cb('0x6')](function(_0x59d762){const _0x24b099=_0x53e9cb;logger[_0x24b099('0x1')](_0x24b099('0x4'),_0x59d762[_0x24b099('0x7')],_0xc86429),_0x2a5213(_0x17160d[_0x24b099('0x1')](0x1f4,_0x59d762['message']));});});},exports[_0xce8077('0x3')]=function(_0xc59849){const _0x49da3b=this;return new Promise(function(_0x98eda7,_0x90b53b){const _0x531117=a69_0x34c5;return db['ChatInteraction']['findOne']({'where':_0xc59849['options']?_0xc59849[_0x531117('0x9')][_0x531117('0x12')]||null:null})[_0x531117('0x8')](function(_0x3634bd){const _0x5144e8=_0x531117;if(_0x3634bd)return _0x3634bd['addTags'](_0xc59849[_0x5144e8('0x5')]['ids'],{'through':_['omit'](_0xc59849['body'],[_0x5144e8('0x10'),'id'])});})[_0x531117('0x8')](function([_0x591be5]){const _0x1f8eb3=_0x531117;logger[_0x1f8eb3('0x11')](_0x1f8eb3('0xa'),_0xc59849),logger['debug'](_0x1f8eb3('0xa'),_0xc59849,JSON['stringify'](_0x591be5)),_0x98eda7(_0x591be5);})[_0x531117('0x6')](function(_0x23c02f){const _0x316bd5=_0x531117;logger['error'](_0x316bd5('0xa'),_0x23c02f[_0x316bd5('0x7')],_0xc59849),_0x90b53b(_0x49da3b[_0x316bd5('0x1')](0x1f4,_0x23c02f[_0x316bd5('0x7')]));});});};
\ No newline at end of file