Built motion from commit f738f9592c388b9f9eb3948f400a5c9d717a3561. Version 3.0.0...
[motion-next.git] / server / api / analyticMetric / analyticMetric.controller.js
index 1431eb0..fd1092a 100644 (file)
@@ -1 +1 @@
-const a26_0xd926=['set','catch','api','stack','destroy','AnalyticMetric','UserProfileSection','attributes','length','role','create','index','params','where','findOne','userProfileId','merge','autoAssociation','body','undefined','fieldName','error','order','Unable\x20to\x20retrieve\x20the\x20current\x20user','../../mysqldb','rawAttributes','offset','include','model','name','then','VIRTUAL','filters','get','send','sequelize','query','key','count','user','status','Metrics','keys','includeAll','filter','sendStatus','limit','options','map','../../components/parsers/qs','update','json','like','sort','Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','nolimit','pick','../../config/logger','fields','intersection','UserProfileResource','rows'];(function(_0x53d547,_0x5df8f7){const _0xd92637=function(_0x4129eb){while(--_0x4129eb){_0x53d547['push'](_0x53d547['shift']());}};_0xd92637(++_0x5df8f7);}(a26_0xd926,0xe7));const a26_0x4129=function(_0x53d547,_0x5df8f7){_0x53d547=_0x53d547-0x9b;let _0xd92637=a26_0xd926[_0x53d547];return _0xd92637;};const a26_0x3576c8=a26_0x4129;'use strict';const _=require('lodash'),qs=require(a26_0x3576c8(0x9f)),logger=require(a26_0x3576c8(0xa7))(a26_0x3576c8(0xae)),{db}=require(a26_0x3576c8(0xc4)),{Op}=require(a26_0x3576c8(0xcf));function respondWithResult(_0x2f7d43,_0x7adeda){return _0x7adeda=_0x7adeda||0xc8,function(_0x3bbb9e){const _0x5ade36=a26_0x4129;if(_0x3bbb9e)return _0x2f7d43[_0x5ade36(0xd4)](_0x7adeda)[_0x5ade36(0xa1)](_0x3bbb9e);};}function respondWithFilteredResult(_0x120dc2,_0x3f4761){return function(_0x48a416){const _0x177aea=a26_0x4129;if(_0x48a416){const _0x37a32e=_0x48a416['count'],_0xe8f105=_0x3f4761[_0x177aea(0xc6)];let _0x256e3c=_0x3f4761[_0x177aea(0xc6)]+_0x3f4761['limit'],_0x1cb996;return _0x256e3c>=_0x37a32e?(_0x256e3c=_0x37a32e,_0x1cb996=0xc8):_0x1cb996=0xce,_0x120dc2['status'](_0x1cb996),_0x120dc2[_0x177aea(0xac)]('Content-Range',_0xe8f105+'-'+_0x256e3c+'/'+_0x37a32e)['json'](_0x48a416);}return null;};}function saveUpdates(_0xa317db){return function(_0x4d7374){const _0x838872=a26_0x4129;if(_0x4d7374)return _0x4d7374[_0x838872(0xa0)](_0xa317db)[_0x838872(0xca)](function(_0x2540eb){return _0x2540eb;});return null;};}function removeEntity(_0x1c03c7){return function(_0xbb553a){const _0x27f5fe=a26_0x4129;if(_0xbb553a)return _0xbb553a[_0x27f5fe(0xb0)]()[_0x27f5fe(0xca)](function(){const _0x8ef0b=_0x27f5fe,_0x3d021b=_0xbb553a[_0x8ef0b(0xcd)]({'plain':!![]}),_0x4685a8=_0x8ef0b(0xd5);return db[_0x8ef0b(0xaa)][_0x8ef0b(0xb0)]({'where':{'type':_0x4685a8,'resourceId':_0x3d021b['id']}})[_0x8ef0b(0xca)](function(){return _0xbb553a;});})[_0x27f5fe(0xca)](function(){const _0x2f34d7=_0x27f5fe;_0x1c03c7[_0x2f34d7(0xd4)](0xcc)['end']();});};}function handleEntityNotFound(_0x3220a0){return function(_0x2d22e5){const _0x17a080=a26_0x4129;return!_0x2d22e5&&_0x3220a0[_0x17a080(0x9b)](0x194),_0x2d22e5;};}function handleError(_0x512d2b,_0x4b3297){return _0x4b3297=_0x4b3297||0x1f4,function(_0x36dd58){const _0x29651e=a26_0x4129;logger[_0x29651e(0xc1)](_0x36dd58[_0x29651e(0xaf)]),_0x36dd58['name']&&delete _0x36dd58[_0x29651e(0xc9)],_0x512d2b['status'](_0x4b3297)[_0x29651e(0xce)](_0x36dd58);};}exports[a26_0x3576c8(0xb7)]=function(_0x8282f4,_0x402f93){const _0xadf0cc=a26_0x3576c8;let _0x3e64ec={};const _0x140f5b={},_0x18fcc8={'count':0x0,'rows':[]},_0x2a39b3=_[_0xadf0cc(0x9e)](db[_0xadf0cc(0xb1)]['rawAttributes'],function(_0xa3619c){const _0x1d0462=_0xadf0cc;return{'name':_0xa3619c[_0x1d0462(0xc0)],'type':_0xa3619c['type'][_0x1d0462(0xd1)]};});_0x140f5b['model']=_[_0xadf0cc(0x9e)](_0x2a39b3,_0xadf0cc(0xc9)),_0x140f5b[_0xadf0cc(0xd0)]=_[_0xadf0cc(0xd6)](_0x8282f4[_0xadf0cc(0xd0)]),_0x140f5b[_0xadf0cc(0xcc)]=_['intersection'](_0x140f5b[_0xadf0cc(0xc8)],_0x140f5b[_0xadf0cc(0xd0)]),_0x3e64ec[_0xadf0cc(0xb3)]=_[_0xadf0cc(0xa9)](_0x140f5b[_0xadf0cc(0xc8)],qs[_0xadf0cc(0xa8)](_0x8282f4[_0xadf0cc(0xd0)][_0xadf0cc(0xa8)])),_0x3e64ec['attributes']=_0x3e64ec[_0xadf0cc(0xb3)]['length']?_0x3e64ec['attributes']:_0x140f5b['model'];typeof _0x8282f4[_0xadf0cc(0xd0)][_0xadf0cc(0xa5)]===_0xadf0cc(0xbf)&&(_0x3e64ec[_0xadf0cc(0x9c)]=qs[_0xadf0cc(0x9c)](_0x8282f4[_0xadf0cc(0xd0)][_0xadf0cc(0x9c)]),_0x3e64ec[_0xadf0cc(0xc6)]=qs['offset'](_0x8282f4['query'][_0xadf0cc(0xc6)]));_0x3e64ec[_0xadf0cc(0xc2)]=qs[_0xadf0cc(0xa3)](_0x8282f4[_0xadf0cc(0xd0)][_0xadf0cc(0xa3)]),_0x3e64ec['where']=qs[_0xadf0cc(0xcc)](_[_0xadf0cc(0xa6)](_0x8282f4['query'],_0x140f5b['filters']),_0x2a39b3);_0x8282f4[_0xadf0cc(0xd0)][_0xadf0cc(0xd8)]&&(_0x3e64ec['where']=_[_0xadf0cc(0xbc)](_0x3e64ec[_0xadf0cc(0xb9)],{[Op['or']]:_[_0xadf0cc(0x9e)](_0x2a39b3,function(_0x14ad22){const _0x3b9485=_0xadf0cc;if(_0x14ad22['type']!==_0x3b9485(0xcb)){const _0x505269={};return _0x505269[_0x14ad22[_0x3b9485(0xc9)]]={[Op[_0x3b9485(0xa2)]]:'%'+_0x8282f4[_0x3b9485(0xd0)]['filter']+'%'},_0x505269;}})}));_0x3e64ec=_['merge']({},_0x3e64ec,_0x8282f4[_0xadf0cc(0x9d)]);const _0x2a08e5={'where':_0x3e64ec[_0xadf0cc(0xb9)]};return db[_0xadf0cc(0xb1)][_0xadf0cc(0xd2)](_0x2a08e5)[_0xadf0cc(0xca)](function(_0x112f8c){const _0x41324c=_0xadf0cc;return _0x18fcc8[_0x41324c(0xd2)]=_0x112f8c,_0x8282f4[_0x41324c(0xd0)][_0x41324c(0xd7)]&&(_0x3e64ec[_0x41324c(0xc7)]=[{'all':!![]}]),db[_0x41324c(0xb1)]['findAll'](_0x3e64ec);})['then'](function(_0x1989ae){const _0x171fad=_0xadf0cc;return _0x18fcc8[_0x171fad(0xab)]=_0x1989ae,_0x18fcc8;})['then'](respondWithFilteredResult(_0x402f93,_0x3e64ec))['catch'](handleError(_0x402f93,null));},exports['show']=function(_0x540525,_0x302fca){const _0x74a15b=a26_0x3576c8;let _0x4e4018={'raw':!![],'where':{'id':_0x540525[_0x74a15b(0xb8)]['id']}};const _0x6210f2={};return _0x6210f2[_0x74a15b(0xc8)]=_[_0x74a15b(0xd6)](db[_0x74a15b(0xb1)][_0x74a15b(0xc5)]),_0x6210f2[_0x74a15b(0xd0)]=_[_0x74a15b(0xd6)](_0x540525[_0x74a15b(0xd0)]),_0x6210f2[_0x74a15b(0xcc)]=_[_0x74a15b(0xa9)](_0x6210f2['model'],_0x6210f2['query']),_0x4e4018[_0x74a15b(0xb3)]=_[_0x74a15b(0xa9)](_0x6210f2[_0x74a15b(0xc8)],qs[_0x74a15b(0xa8)](_0x540525['query'][_0x74a15b(0xa8)])),_0x4e4018[_0x74a15b(0xb3)]=_0x4e4018[_0x74a15b(0xb3)][_0x74a15b(0xb4)]?_0x4e4018[_0x74a15b(0xb3)]:_0x6210f2[_0x74a15b(0xc8)],_0x540525[_0x74a15b(0xd0)]['includeAll']&&(_0x4e4018[_0x74a15b(0xc7)]=[{'all':!![]}]),_0x4e4018=_[_0x74a15b(0xbc)]({},_0x4e4018,_0x540525[_0x74a15b(0x9d)]),db[_0x74a15b(0xb1)][_0x74a15b(0xba)](_0x4e4018)[_0x74a15b(0xca)](handleEntityNotFound(_0x302fca,null))[_0x74a15b(0xca)](respondWithResult(_0x302fca,null))[_0x74a15b(0xad)](handleError(_0x302fca,null));},exports[a26_0x3576c8(0xb6)]=function(_0x1dce36,_0x45a8ff){const _0x21ad01=a26_0x3576c8;return db[_0x21ad01(0xb1)]['create'](_0x1dce36[_0x21ad01(0xbe)],{})['then'](function(_0x4f8c37){const _0x5982ea=_0x21ad01,_0xdacd35=_0x1dce36['user'][_0x5982ea(0xcd)]({'plain':!![]});if(!_0xdacd35)throw new Error(_0x5982ea(0xc3));if(_0xdacd35[_0x5982ea(0xb5)]===_0x5982ea(0xd3)){const _0x4ef4cb=_0x4f8c37[_0x5982ea(0xcd)]({'plain':!![]}),_0x11c6aa='Metrics';return db[_0x5982ea(0xb2)][_0x5982ea(0xba)]({'where':{'name':_0x11c6aa,'userProfileId':_0xdacd35[_0x5982ea(0xbb)]},'raw':!![]})['then'](function(_0x4fa7f0){const _0x33f895=_0x5982ea;return _0x4fa7f0&&_0x4fa7f0[_0x33f895(0xbd)]===0x0?db[_0x33f895(0xaa)][_0x33f895(0xb6)]({'name':_0x4ef4cb[_0x33f895(0xc9)],'resourceId':_0x4ef4cb['id'],'type':_0x4fa7f0[_0x33f895(0xc9)],'sectionId':_0x4fa7f0['id']},{})['then'](function(){return _0x4f8c37;}):_0x4f8c37;})[_0x5982ea(0xad)](function(_0xfa7ec6){const _0x357761=_0x5982ea;logger['error'](_0x357761(0xa4),_0xfa7ec6);throw _0xfa7ec6;});}return _0x4f8c37;})[_0x21ad01(0xca)](respondWithResult(_0x45a8ff,0xc9))['catch'](handleError(_0x45a8ff,null));},exports['update']=function(_0xdcea0b,_0x2789cd){const _0x1f4054=a26_0x3576c8;return _0xdcea0b[_0x1f4054(0xbe)]['id']&&delete _0xdcea0b[_0x1f4054(0xbe)]['id'],db['AnalyticMetric'][_0x1f4054(0xba)]({'where':{'id':_0xdcea0b[_0x1f4054(0xb8)]['id']}})[_0x1f4054(0xca)](handleEntityNotFound(_0x2789cd,null))[_0x1f4054(0xca)](saveUpdates(_0xdcea0b[_0x1f4054(0xbe)],null))['then'](respondWithResult(_0x2789cd,null))[_0x1f4054(0xad)](handleError(_0x2789cd,null));},exports['destroy']=function(_0x1f3a23,_0x155fdc){const _0x15e956=a26_0x3576c8;return db[_0x15e956(0xb1)][_0x15e956(0xba)]({'where':{'id':_0x1f3a23[_0x15e956(0xb8)]['id']}})[_0x15e956(0xca)](handleEntityNotFound(_0x155fdc,null))[_0x15e956(0xca)](removeEntity(_0x155fdc,null))['catch'](handleError(_0x155fdc,null));};
\ No newline at end of file
+const a26_0x422a=['Unable\x20to\x20associate\x20the\x20resource\x20to\x20the\x20User\x20Profile:\x20%s','body','role','UserProfileSection','model','includeAll','lodash','pick','offset','json','UserProfileResource','Unable\x20to\x20retrieve\x20the\x20current\x20user','where','end','destroy','filter','options','undefined','filters','userProfileId','name','keys','attributes','status','findOne','user','merge','type','api','AnalyticMetric','limit','sort','intersection','findAll','update','send','sequelize','fieldName','map','create','../../config/logger','set','key','fields','rows','length','nolimit','rawAttributes','query','get','catch','params','Metrics','../../mysqldb','count','then','../../components/parsers/qs','index','error'];(function(_0x3866b2,_0x41a6bc){const _0x422a86=function(_0x1574ca){while(--_0x1574ca){_0x3866b2['push'](_0x3866b2['shift']());}};_0x422a86(++_0x41a6bc);}(a26_0x422a,0xc0));const a26_0x1574=function(_0x3866b2,_0x41a6bc){_0x3866b2=_0x3866b2-0x16e;let _0x422a86=a26_0x422a[_0x3866b2];return _0x422a86;};const a26_0x1afdbd=a26_0x1574;'use strict';const _=require(a26_0x1afdbd(0x1a0)),qs=require(a26_0x1afdbd(0x197)),logger=require(a26_0x1afdbd(0x187))(a26_0x1afdbd(0x17b)),{db}=require(a26_0x1afdbd(0x194)),{Op}=require(a26_0x1afdbd(0x183));function respondWithResult(_0x303ef9,_0x3f5f1a){return _0x3f5f1a=_0x3f5f1a||0xc8,function(_0x118e95){const _0x141c6b=a26_0x1574;if(_0x118e95)return _0x303ef9[_0x141c6b(0x176)](_0x3f5f1a)[_0x141c6b(0x1a3)](_0x118e95);};}function respondWithFilteredResult(_0x5d1c4f,_0x34f23d){return function(_0x14c425){const _0x31e8e9=a26_0x1574;if(_0x14c425){const _0xc6bc41=_0x14c425[_0x31e8e9(0x195)],_0x4493b4=_0x34f23d[_0x31e8e9(0x1a2)];let _0x415fed=_0x34f23d[_0x31e8e9(0x1a2)]+_0x34f23d['limit'],_0x39134d;return _0x415fed>=_0xc6bc41?(_0x415fed=_0xc6bc41,_0x39134d=0xc8):_0x39134d=0xce,_0x5d1c4f[_0x31e8e9(0x176)](_0x39134d),_0x5d1c4f[_0x31e8e9(0x188)]('Content-Range',_0x4493b4+'-'+_0x415fed+'/'+_0xc6bc41)['json'](_0x14c425);}return null;};}function saveUpdates(_0x54cafc){return function(_0x4245a1){const _0x21b48c=a26_0x1574;if(_0x4245a1)return _0x4245a1[_0x21b48c(0x181)](_0x54cafc)['then'](function(_0x5c49a2){return _0x5c49a2;});return null;};}function removeEntity(_0x4790df){return function(_0xe69698){const _0x25149a=a26_0x1574;if(_0xe69698)return _0xe69698[_0x25149a(0x1a8)]()[_0x25149a(0x196)](function(){const _0x49a85f=_0x25149a,_0x12d97b=_0xe69698['get']({'plain':!![]}),_0x1c0988=_0x49a85f(0x193);return db[_0x49a85f(0x1a4)]['destroy']({'where':{'type':_0x1c0988,'resourceId':_0x12d97b['id']}})['then'](function(){return _0xe69698;});})[_0x25149a(0x196)](function(){const _0x3062d1=_0x25149a;_0x4790df[_0x3062d1(0x176)](0xcc)[_0x3062d1(0x1a7)]();});};}function handleEntityNotFound(_0x5753ae){return function(_0x3fdcb0){return!_0x3fdcb0&&_0x5753ae['sendStatus'](0x194),_0x3fdcb0;};}function handleError(_0x23207f,_0x336f48){return _0x336f48=_0x336f48||0x1f4,function(_0x1ca1c1){const _0x30d982=a26_0x1574;logger[_0x30d982(0x199)](_0x1ca1c1['stack']),_0x1ca1c1['name']&&delete _0x1ca1c1[_0x30d982(0x173)],_0x23207f[_0x30d982(0x176)](_0x336f48)[_0x30d982(0x182)](_0x1ca1c1);};}exports[a26_0x1afdbd(0x198)]=function(_0x550857,_0x9faae7){const _0x3d4256=a26_0x1afdbd;let _0x3e32a4={};const _0x462a38={},_0x4cfc9e={'count':0x0,'rows':[]},_0x672378=_[_0x3d4256(0x185)](db[_0x3d4256(0x17c)][_0x3d4256(0x18e)],function(_0x1addaa){const _0x2b8c6b=_0x3d4256;return{'name':_0x1addaa[_0x2b8c6b(0x184)],'type':_0x1addaa[_0x2b8c6b(0x17a)][_0x2b8c6b(0x189)]};});_0x462a38[_0x3d4256(0x19e)]=_[_0x3d4256(0x185)](_0x672378,'name'),_0x462a38[_0x3d4256(0x18f)]=_[_0x3d4256(0x174)](_0x550857[_0x3d4256(0x18f)]),_0x462a38[_0x3d4256(0x171)]=_[_0x3d4256(0x17f)](_0x462a38[_0x3d4256(0x19e)],_0x462a38[_0x3d4256(0x18f)]),_0x3e32a4[_0x3d4256(0x175)]=_[_0x3d4256(0x17f)](_0x462a38[_0x3d4256(0x19e)],qs[_0x3d4256(0x18a)](_0x550857['query'][_0x3d4256(0x18a)])),_0x3e32a4['attributes']=_0x3e32a4[_0x3d4256(0x175)][_0x3d4256(0x18c)]?_0x3e32a4['attributes']:_0x462a38[_0x3d4256(0x19e)];typeof _0x550857[_0x3d4256(0x18f)][_0x3d4256(0x18d)]===_0x3d4256(0x170)&&(_0x3e32a4[_0x3d4256(0x17d)]=qs['limit'](_0x550857['query']['limit']),_0x3e32a4[_0x3d4256(0x1a2)]=qs[_0x3d4256(0x1a2)](_0x550857[_0x3d4256(0x18f)]['offset']));_0x3e32a4['order']=qs[_0x3d4256(0x17e)](_0x550857[_0x3d4256(0x18f)]['sort']),_0x3e32a4['where']=qs[_0x3d4256(0x171)](_[_0x3d4256(0x1a1)](_0x550857[_0x3d4256(0x18f)],_0x462a38[_0x3d4256(0x171)]),_0x672378);_0x550857[_0x3d4256(0x18f)][_0x3d4256(0x16e)]&&(_0x3e32a4['where']=_['merge'](_0x3e32a4[_0x3d4256(0x1a6)],{[Op['or']]:_[_0x3d4256(0x185)](_0x672378,function(_0x16cc0b){const _0x4cfb4e=_0x3d4256;if(_0x16cc0b[_0x4cfb4e(0x17a)]!=='VIRTUAL'){const _0x482202={};return _0x482202[_0x16cc0b['name']]={[Op['like']]:'%'+_0x550857[_0x4cfb4e(0x18f)][_0x4cfb4e(0x16e)]+'%'},_0x482202;}})}));_0x3e32a4=_[_0x3d4256(0x179)]({},_0x3e32a4,_0x550857[_0x3d4256(0x16f)]);const _0x3e3b86={'where':_0x3e32a4[_0x3d4256(0x1a6)]};return db[_0x3d4256(0x17c)][_0x3d4256(0x195)](_0x3e3b86)[_0x3d4256(0x196)](function(_0x404ba2){const _0x16f273=_0x3d4256;return _0x4cfc9e['count']=_0x404ba2,_0x550857[_0x16f273(0x18f)][_0x16f273(0x19f)]&&(_0x3e32a4['include']=[{'all':!![]}]),db[_0x16f273(0x17c)][_0x16f273(0x180)](_0x3e32a4);})[_0x3d4256(0x196)](function(_0x10d036){const _0x53ad53=_0x3d4256;return _0x4cfc9e[_0x53ad53(0x18b)]=_0x10d036,_0x4cfc9e;})[_0x3d4256(0x196)](respondWithFilteredResult(_0x9faae7,_0x3e32a4))[_0x3d4256(0x191)](handleError(_0x9faae7,null));},exports['show']=function(_0xc66389,_0x420111){const _0x506334=a26_0x1afdbd;let _0x4103c9={'raw':!![],'where':{'id':_0xc66389[_0x506334(0x192)]['id']}};const _0x13617a={};return _0x13617a[_0x506334(0x19e)]=_[_0x506334(0x174)](db[_0x506334(0x17c)][_0x506334(0x18e)]),_0x13617a['query']=_[_0x506334(0x174)](_0xc66389['query']),_0x13617a[_0x506334(0x171)]=_['intersection'](_0x13617a['model'],_0x13617a[_0x506334(0x18f)]),_0x4103c9[_0x506334(0x175)]=_[_0x506334(0x17f)](_0x13617a['model'],qs['fields'](_0xc66389[_0x506334(0x18f)]['fields'])),_0x4103c9[_0x506334(0x175)]=_0x4103c9['attributes'][_0x506334(0x18c)]?_0x4103c9[_0x506334(0x175)]:_0x13617a[_0x506334(0x19e)],_0xc66389['query'][_0x506334(0x19f)]&&(_0x4103c9['include']=[{'all':!![]}]),_0x4103c9=_[_0x506334(0x179)]({},_0x4103c9,_0xc66389[_0x506334(0x16f)]),db[_0x506334(0x17c)][_0x506334(0x177)](_0x4103c9)[_0x506334(0x196)](handleEntityNotFound(_0x420111,null))[_0x506334(0x196)](respondWithResult(_0x420111,null))[_0x506334(0x191)](handleError(_0x420111,null));},exports[a26_0x1afdbd(0x186)]=function(_0x44375b,_0x9431d9){const _0x4ef204=a26_0x1afdbd;return db[_0x4ef204(0x17c)][_0x4ef204(0x186)](_0x44375b['body'],{})[_0x4ef204(0x196)](function(_0x570d5d){const _0x4cf96d=_0x4ef204,_0x38240f=_0x44375b['user']['get']({'plain':!![]});if(!_0x38240f)throw new Error(_0x4cf96d(0x1a5));if(_0x38240f[_0x4cf96d(0x19c)]===_0x4cf96d(0x178)){const _0x1f68b2=_0x570d5d[_0x4cf96d(0x190)]({'plain':!![]}),_0x578636=_0x4cf96d(0x193);return db[_0x4cf96d(0x19d)]['findOne']({'where':{'name':_0x578636,'userProfileId':_0x38240f[_0x4cf96d(0x172)]},'raw':!![]})['then'](function(_0x1100db){const _0x31c8cf=_0x4cf96d;return _0x1100db&&_0x1100db['autoAssociation']===0x0?db[_0x31c8cf(0x1a4)]['create']({'name':_0x1f68b2[_0x31c8cf(0x173)],'resourceId':_0x1f68b2['id'],'type':_0x1100db[_0x31c8cf(0x173)],'sectionId':_0x1100db['id']},{})['then'](function(){return _0x570d5d;}):_0x570d5d;})['catch'](function(_0x50cc6){const _0x21dbb9=_0x4cf96d;logger[_0x21dbb9(0x199)](_0x21dbb9(0x19a),_0x50cc6);throw _0x50cc6;});}return _0x570d5d;})['then'](respondWithResult(_0x9431d9,0xc9))[_0x4ef204(0x191)](handleError(_0x9431d9,null));},exports[a26_0x1afdbd(0x181)]=function(_0x2767bf,_0x229989){const _0x158ca3=a26_0x1afdbd;return _0x2767bf[_0x158ca3(0x19b)]['id']&&delete _0x2767bf[_0x158ca3(0x19b)]['id'],db[_0x158ca3(0x17c)][_0x158ca3(0x177)]({'where':{'id':_0x2767bf[_0x158ca3(0x192)]['id']}})[_0x158ca3(0x196)](handleEntityNotFound(_0x229989,null))['then'](saveUpdates(_0x2767bf[_0x158ca3(0x19b)],null))[_0x158ca3(0x196)](respondWithResult(_0x229989,null))['catch'](handleError(_0x229989,null));},exports[a26_0x1afdbd(0x1a8)]=function(_0x25e041,_0x2ea2c8){const _0x2fb8a3=a26_0x1afdbd;return db[_0x2fb8a3(0x17c)][_0x2fb8a3(0x177)]({'where':{'id':_0x25e041[_0x2fb8a3(0x192)]['id']}})[_0x2fb8a3(0x196)](handleEntityNotFound(_0x2ea2c8,null))[_0x2fb8a3(0x196)](removeEntity(_0x2ea2c8,null))['catch'](handleError(_0x2ea2c8,null));};
\ No newline at end of file