Built motion from commit 092f8824.|2.5.49
[motion2.git] / server / api / whatsappApplication / whatsappApplication.controller.js
index 5d03e58..a8a4715 100644 (file)
@@ -15,4 +15,4 @@
 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                        *
 // *                                                                       *
 // *************************************************************************
-var _0xf4ce=['then','error','name','index','fieldName','type','key','model','map','query','keys','filters','intersection','attributes','fields','length','hasOwnProperty','nolimit','order','sort','where','pick','filter','merge','VIRTUAL','options','findAll','rows','catch','WhatsappApplication','rawAttributes','includeAll','include','find','create','body','params','destroy','eml-format','fast-json-patch','request-promise','moment','bluebird','ejs','fs-extra','lodash','squel','crypto','jsforce','to-csv','querystring','../../components/parsers/qs','../../components/parsers/advancedSearch','../../config/license/hardware','../../config/logger','../../config/utils','../../mysqldb','status','end','json','offset','undefined','limit','count','Content-Range','apply','save','update'];(function(_0x13b02f,_0x462a53){var _0x12e9a6=function(_0x187d57){while(--_0x187d57){_0x13b02f['push'](_0x13b02f['shift']());}};_0x12e9a6(++_0x462a53);}(_0xf4ce,0xf2));var _0xef4c=function(_0x2dafbe,_0x5d04de){_0x2dafbe=_0x2dafbe-0x0;var _0x58a45a=_0xf4ce[_0x2dafbe];return _0x58a45a;};'use strict';var emlformat=require(_0xef4c('0x0'));var rimraf=require('rimraf');var zipdir=require('zip-dir');var jsonpatch=require(_0xef4c('0x1'));var rp=require(_0xef4c('0x2'));var moment=require(_0xef4c('0x3'));var BPromise=require(_0xef4c('0x4'));var Mustache=require('mustache');var util=require('util');var path=require('path');var sox=require('sox');var csv=require('to-csv');var ejs=require(_0xef4c('0x5'));var fs=require('fs');var fs_extra=require(_0xef4c('0x6'));var _=require(_0xef4c('0x7'));var squel=require(_0xef4c('0x8'));var crypto=require(_0xef4c('0x9'));var jsforce=require(_0xef4c('0xa'));var deskjs=require('desk.js');var toCsv=require(_0xef4c('0xb'));var querystring=require(_0xef4c('0xc'));var Papa=require('papaparse');var Redis=require('ioredis');var authService=require('../../components/auth/service');var qs=require(_0xef4c('0xd'));var as=require(_0xef4c('0xe'));var hardwareService=require(_0xef4c('0xf'));var logger=require(_0xef4c('0x10'))('api');var utils=require(_0xef4c('0x11'));var config=require('../../config/environment');var licenseUtil=require('../../config/license/util');var db=require(_0xef4c('0x12'))['db'];function respondWithStatusCode(_0x3bda49,_0x2bfe28){_0x2bfe28=_0x2bfe28||0xcc;return function(_0x6a1290){if(_0x6a1290){return _0x3bda49['sendStatus'](_0x2bfe28);}return _0x3bda49[_0xef4c('0x13')](_0x2bfe28)[_0xef4c('0x14')]();};}function respondWithResult(_0x12d7a6,_0x417f67){_0x417f67=_0x417f67||0xc8;return function(_0x2a2631){if(_0x2a2631){return _0x12d7a6[_0xef4c('0x13')](_0x417f67)[_0xef4c('0x15')](_0x2a2631);}};}function respondWithFilteredResult(_0x1c7633,_0x5dc6a3){return function(_0x55a7aa){if(_0x55a7aa){var _0x3637ce=typeof _0x5dc6a3[_0xef4c('0x16')]===_0xef4c('0x17')&&typeof _0x5dc6a3[_0xef4c('0x18')]===_0xef4c('0x17');var _0x371f2a=_0x55a7aa[_0xef4c('0x19')];var _0x446847=_0x3637ce?0x0:_0x5dc6a3[_0xef4c('0x16')];var _0x2bcc97=_0x3637ce?_0x55a7aa[_0xef4c('0x19')]:_0x5dc6a3[_0xef4c('0x16')]+_0x5dc6a3[_0xef4c('0x18')];var _0x560486;if(_0x2bcc97>=_0x371f2a){_0x2bcc97=_0x371f2a;_0x560486=0xc8;}else{_0x560486=0xce;}_0x1c7633[_0xef4c('0x13')](_0x560486);return _0x1c7633['set'](_0xef4c('0x1a'),_0x446847+'-'+_0x2bcc97+'/'+_0x371f2a)[_0xef4c('0x15')](_0x55a7aa);}return null;};}function patchUpdates(_0x46f556){return function(_0xd4e0a){try{jsonpatch[_0xef4c('0x1b')](_0xd4e0a,_0x46f556,!![]);}catch(_0x3bf901){return BPromise['reject'](_0x3bf901);}return _0xd4e0a[_0xef4c('0x1c')]();};}function saveUpdates(_0x460860,_0x500bd3){return function(_0x251e29){if(_0x251e29){return _0x251e29[_0xef4c('0x1d')](_0x460860)[_0xef4c('0x1e')](function(_0x4f4a3a){return _0x4f4a3a;});}return null;};}function removeEntity(_0x1f98a1,_0x17c816){return function(_0x2aca1e){if(_0x2aca1e){return _0x2aca1e['destroy']()[_0xef4c('0x1e')](function(){_0x1f98a1[_0xef4c('0x13')](0xcc)[_0xef4c('0x14')]();});}};}function handleEntityNotFound(_0xfd0013,_0x3f4015){return function(_0x26f523){if(!_0x26f523){_0xfd0013['sendStatus'](0x194);}return _0x26f523;};}function handleError(_0x7e3dd8,_0x286ad3){_0x286ad3=_0x286ad3||0x1f4;return function(_0x35f404){logger[_0xef4c('0x1f')](_0x35f404['stack']);if(_0x35f404[_0xef4c('0x20')]){delete _0x35f404['name'];}_0x7e3dd8[_0xef4c('0x13')](_0x286ad3)['send'](_0x35f404);};}exports[_0xef4c('0x21')]=function(_0x15dfba,_0x39fb17){var _0x13eb57={},_0x8fe191={},_0xb10f30={'count':0x0,'rows':[]};var _0x539486=_['map'](db['WhatsappApplication']['rawAttributes'],function(_0x1d587a){return{'name':_0x1d587a[_0xef4c('0x22')],'type':_0x1d587a[_0xef4c('0x23')][_0xef4c('0x24')]};});_0x8fe191[_0xef4c('0x25')]=_[_0xef4c('0x26')](_0x539486,_0xef4c('0x20'));_0x8fe191[_0xef4c('0x27')]=_[_0xef4c('0x28')](_0x15dfba[_0xef4c('0x27')]);_0x8fe191[_0xef4c('0x29')]=_[_0xef4c('0x2a')](_0x8fe191['model'],_0x8fe191['query']);_0x13eb57[_0xef4c('0x2b')]=_[_0xef4c('0x2a')](_0x8fe191['model'],qs[_0xef4c('0x2c')](_0x15dfba[_0xef4c('0x27')]['fields']));_0x13eb57[_0xef4c('0x2b')]=_0x13eb57[_0xef4c('0x2b')][_0xef4c('0x2d')]?_0x13eb57[_0xef4c('0x2b')]:_0x8fe191['model'];if(!_0x15dfba[_0xef4c('0x27')][_0xef4c('0x2e')](_0xef4c('0x2f'))){_0x13eb57[_0xef4c('0x18')]=qs[_0xef4c('0x18')](_0x15dfba[_0xef4c('0x27')][_0xef4c('0x18')]);_0x13eb57['offset']=qs[_0xef4c('0x16')](_0x15dfba[_0xef4c('0x27')][_0xef4c('0x16')]);}_0x13eb57[_0xef4c('0x30')]=qs[_0xef4c('0x31')](_0x15dfba['query']['sort']);_0x13eb57[_0xef4c('0x32')]=qs[_0xef4c('0x29')](_[_0xef4c('0x33')](_0x15dfba[_0xef4c('0x27')],_0x8fe191[_0xef4c('0x29')]),_0x539486);if(_0x15dfba[_0xef4c('0x27')][_0xef4c('0x34')]){_0x13eb57[_0xef4c('0x32')]=_[_0xef4c('0x35')](_0x13eb57['where'],{'$or':_['map'](_0x539486,function(_0x7f3c9b){if(_0x7f3c9b[_0xef4c('0x23')]!==_0xef4c('0x36')){var _0x14d621={};_0x14d621[_0x7f3c9b[_0xef4c('0x20')]]={'$like':'%'+_0x15dfba[_0xef4c('0x27')][_0xef4c('0x34')]+'%'};return _0x14d621;}})});}_0x13eb57=_[_0xef4c('0x35')]({},_0x13eb57,_0x15dfba[_0xef4c('0x37')]);var _0x19524a={'where':_0x13eb57['where']};return db['WhatsappApplication']['count'](_0x19524a)[_0xef4c('0x1e')](function(_0x519a17){_0xb10f30['count']=_0x519a17;if(_0x15dfba['query']['includeAll']){_0x13eb57['include']=[{'all':!![]}];}return db['WhatsappApplication'][_0xef4c('0x38')](_0x13eb57);})[_0xef4c('0x1e')](function(_0x46edf0){_0xb10f30[_0xef4c('0x39')]=_0x46edf0;return _0xb10f30;})[_0xef4c('0x1e')](respondWithFilteredResult(_0x39fb17,_0x13eb57))[_0xef4c('0x3a')](handleError(_0x39fb17,null));};exports['show']=function(_0x2afdec,_0x35d30e){var _0x1ec099={'raw':!![],'where':{'id':_0x2afdec['params']['id']}},_0x1f7a13={};_0x1f7a13['model']=_[_0xef4c('0x28')](db[_0xef4c('0x3b')][_0xef4c('0x3c')]);_0x1f7a13[_0xef4c('0x27')]=_[_0xef4c('0x28')](_0x2afdec[_0xef4c('0x27')]);_0x1f7a13[_0xef4c('0x29')]=_[_0xef4c('0x2a')](_0x1f7a13['model'],_0x1f7a13['query']);_0x1ec099[_0xef4c('0x2b')]=_['intersection'](_0x1f7a13[_0xef4c('0x25')],qs[_0xef4c('0x2c')](_0x2afdec[_0xef4c('0x27')][_0xef4c('0x2c')]));_0x1ec099[_0xef4c('0x2b')]=_0x1ec099[_0xef4c('0x2b')][_0xef4c('0x2d')]?_0x1ec099[_0xef4c('0x2b')]:_0x1f7a13[_0xef4c('0x25')];if(_0x2afdec[_0xef4c('0x27')][_0xef4c('0x3d')]){_0x1ec099[_0xef4c('0x3e')]=[{'all':!![]}];}_0x1ec099=_['merge']({},_0x1ec099,_0x2afdec[_0xef4c('0x37')]);return db[_0xef4c('0x3b')][_0xef4c('0x3f')](_0x1ec099)[_0xef4c('0x1e')](handleEntityNotFound(_0x35d30e,null))[_0xef4c('0x1e')](respondWithResult(_0x35d30e,null))[_0xef4c('0x3a')](handleError(_0x35d30e,null));};exports['create']=function(_0x2710fc,_0x20a30b){return db[_0xef4c('0x3b')][_0xef4c('0x40')](_0x2710fc['body'],{})[_0xef4c('0x1e')](respondWithResult(_0x20a30b,0xc9))['catch'](handleError(_0x20a30b,null));};exports[_0xef4c('0x1d')]=function(_0x2eb3ad,_0x5e89de){if(_0x2eb3ad[_0xef4c('0x41')]['id']){delete _0x2eb3ad[_0xef4c('0x41')]['id'];}return db['WhatsappApplication'][_0xef4c('0x3f')]({'where':{'id':_0x2eb3ad[_0xef4c('0x42')]['id']}})[_0xef4c('0x1e')](handleEntityNotFound(_0x5e89de,null))['then'](saveUpdates(_0x2eb3ad[_0xef4c('0x41')],null))[_0xef4c('0x1e')](respondWithResult(_0x5e89de,null))[_0xef4c('0x3a')](handleError(_0x5e89de,null));};exports[_0xef4c('0x43')]=function(_0x2d5e1a,_0x27056c){return db[_0xef4c('0x3b')]['find']({'where':{'id':_0x2d5e1a[_0xef4c('0x42')]['id']}})[_0xef4c('0x1e')](handleEntityNotFound(_0x27056c,null))[_0xef4c('0x1e')](removeEntity(_0x27056c,null))[_0xef4c('0x3a')](handleError(_0x27056c,null));};
\ No newline at end of file
+var _0x9e6d=['attributes','length','hasOwnProperty','nolimit','order','sort','where','merge','VIRTUAL','filter','includeAll','include','findAll','rows','params','keys','rawAttributes','options','find','catch','create','body','eml-format','zip-dir','fast-json-patch','request-promise','bluebird','mustache','util','path','to-csv','ejs','squel','crypto','jsforce','querystring','ioredis','../../components/auth/service','../../config/license/hardware','../../config/logger','api','../../config/utils','../../config/environment','../../config/license/util','../../mysqldb','sendStatus','status','json','undefined','count','offset','limit','Content-Range','apply','reject','save','update','then','destroy','end','stack','name','send','index','map','WhatsappApplication','fieldName','type','key','model','query','filters','intersection','fields'];(function(_0x37e845,_0x219f9f){var _0x59e55b=function(_0x5dc6c8){while(--_0x5dc6c8){_0x37e845['push'](_0x37e845['shift']());}};_0x59e55b(++_0x219f9f);}(_0x9e6d,0x1d2));var _0xd9e6=function(_0x574378,_0x18210b){_0x574378=_0x574378-0x0;var _0x4674b8=_0x9e6d[_0x574378];return _0x4674b8;};'use strict';var emlformat=require(_0xd9e6('0x0'));var rimraf=require('rimraf');var zipdir=require(_0xd9e6('0x1'));var jsonpatch=require(_0xd9e6('0x2'));var rp=require(_0xd9e6('0x3'));var moment=require('moment');var BPromise=require(_0xd9e6('0x4'));var Mustache=require(_0xd9e6('0x5'));var util=require(_0xd9e6('0x6'));var path=require(_0xd9e6('0x7'));var sox=require('sox');var csv=require(_0xd9e6('0x8'));var ejs=require(_0xd9e6('0x9'));var fs=require('fs');var fs_extra=require('fs-extra');var _=require('lodash');var squel=require(_0xd9e6('0xa'));var crypto=require(_0xd9e6('0xb'));var jsforce=require(_0xd9e6('0xc'));var deskjs=require('desk.js');var toCsv=require(_0xd9e6('0x8'));var querystring=require(_0xd9e6('0xd'));var Papa=require('papaparse');var Redis=require(_0xd9e6('0xe'));var authService=require(_0xd9e6('0xf'));var qs=require('../../components/parsers/qs');var as=require('../../components/parsers/advancedSearch');var hardwareService=require(_0xd9e6('0x10'));var logger=require(_0xd9e6('0x11'))(_0xd9e6('0x12'));var utils=require(_0xd9e6('0x13'));var config=require(_0xd9e6('0x14'));var licenseUtil=require(_0xd9e6('0x15'));var db=require(_0xd9e6('0x16'))['db'];function respondWithStatusCode(_0x350b53,_0x3bb322){_0x3bb322=_0x3bb322||0xcc;return function(_0x590c7b){if(_0x590c7b){return _0x350b53[_0xd9e6('0x17')](_0x3bb322);}return _0x350b53[_0xd9e6('0x18')](_0x3bb322)['end']();};}function respondWithResult(_0x51e0b2,_0x1b32bb){_0x1b32bb=_0x1b32bb||0xc8;return function(_0x5a9940){if(_0x5a9940){return _0x51e0b2[_0xd9e6('0x18')](_0x1b32bb)[_0xd9e6('0x19')](_0x5a9940);}};}function respondWithFilteredResult(_0x1404d6,_0x1591d5){return function(_0x79ce6a){if(_0x79ce6a){var _0x4eb591=typeof _0x1591d5['offset']===_0xd9e6('0x1a')&&typeof _0x1591d5['limit']===_0xd9e6('0x1a');var _0x232770=_0x79ce6a[_0xd9e6('0x1b')];var _0x2db831=_0x4eb591?0x0:_0x1591d5[_0xd9e6('0x1c')];var _0xa7fa90=_0x4eb591?_0x79ce6a[_0xd9e6('0x1b')]:_0x1591d5[_0xd9e6('0x1c')]+_0x1591d5[_0xd9e6('0x1d')];var _0x2604a0;if(_0xa7fa90>=_0x232770){_0xa7fa90=_0x232770;_0x2604a0=0xc8;}else{_0x2604a0=0xce;}_0x1404d6['status'](_0x2604a0);return _0x1404d6['set'](_0xd9e6('0x1e'),_0x2db831+'-'+_0xa7fa90+'/'+_0x232770)[_0xd9e6('0x19')](_0x79ce6a);}return null;};}function patchUpdates(_0x19dfd7){return function(_0x4a6e39){try{jsonpatch[_0xd9e6('0x1f')](_0x4a6e39,_0x19dfd7,!![]);}catch(_0x106026){return BPromise[_0xd9e6('0x20')](_0x106026);}return _0x4a6e39[_0xd9e6('0x21')]();};}function saveUpdates(_0x4f8db1,_0x4e7873){return function(_0x162e67){if(_0x162e67){return _0x162e67[_0xd9e6('0x22')](_0x4f8db1)[_0xd9e6('0x23')](function(_0x5dc0bd){return _0x5dc0bd;});}return null;};}function removeEntity(_0x33158e,_0x370c64){return function(_0x2393b9){if(_0x2393b9){return _0x2393b9[_0xd9e6('0x24')]()[_0xd9e6('0x23')](function(){_0x33158e[_0xd9e6('0x18')](0xcc)[_0xd9e6('0x25')]();});}};}function handleEntityNotFound(_0x5e2eef,_0x3a8c62){return function(_0x3b17f9){if(!_0x3b17f9){_0x5e2eef[_0xd9e6('0x17')](0x194);}return _0x3b17f9;};}function handleError(_0x3ea715,_0x147a4f){_0x147a4f=_0x147a4f||0x1f4;return function(_0x3e8b29){logger['error'](_0x3e8b29[_0xd9e6('0x26')]);if(_0x3e8b29[_0xd9e6('0x27')]){delete _0x3e8b29[_0xd9e6('0x27')];}_0x3ea715[_0xd9e6('0x18')](_0x147a4f)[_0xd9e6('0x28')](_0x3e8b29);};}exports[_0xd9e6('0x29')]=function(_0x105831,_0x2b2f4b){var _0x3e98d6={},_0x874243={},_0x3470f5={'count':0x0,'rows':[]};var _0x3c4043=_[_0xd9e6('0x2a')](db[_0xd9e6('0x2b')]['rawAttributes'],function(_0x339d5f){return{'name':_0x339d5f[_0xd9e6('0x2c')],'type':_0x339d5f[_0xd9e6('0x2d')][_0xd9e6('0x2e')]};});_0x874243[_0xd9e6('0x2f')]=_[_0xd9e6('0x2a')](_0x3c4043,_0xd9e6('0x27'));_0x874243[_0xd9e6('0x30')]=_['keys'](_0x105831[_0xd9e6('0x30')]);_0x874243[_0xd9e6('0x31')]=_[_0xd9e6('0x32')](_0x874243['model'],_0x874243[_0xd9e6('0x30')]);_0x3e98d6['attributes']=_[_0xd9e6('0x32')](_0x874243[_0xd9e6('0x2f')],qs['fields'](_0x105831['query'][_0xd9e6('0x33')]));_0x3e98d6[_0xd9e6('0x34')]=_0x3e98d6['attributes'][_0xd9e6('0x35')]?_0x3e98d6['attributes']:_0x874243[_0xd9e6('0x2f')];if(!_0x105831[_0xd9e6('0x30')][_0xd9e6('0x36')](_0xd9e6('0x37'))){_0x3e98d6[_0xd9e6('0x1d')]=qs[_0xd9e6('0x1d')](_0x105831[_0xd9e6('0x30')][_0xd9e6('0x1d')]);_0x3e98d6['offset']=qs['offset'](_0x105831[_0xd9e6('0x30')][_0xd9e6('0x1c')]);}_0x3e98d6[_0xd9e6('0x38')]=qs[_0xd9e6('0x39')](_0x105831[_0xd9e6('0x30')][_0xd9e6('0x39')]);_0x3e98d6[_0xd9e6('0x3a')]=qs[_0xd9e6('0x31')](_['pick'](_0x105831[_0xd9e6('0x30')],_0x874243[_0xd9e6('0x31')]),_0x3c4043);if(_0x105831[_0xd9e6('0x30')]['filter']){_0x3e98d6[_0xd9e6('0x3a')]=_[_0xd9e6('0x3b')](_0x3e98d6[_0xd9e6('0x3a')],{'$or':_[_0xd9e6('0x2a')](_0x3c4043,function(_0x3012f6){if(_0x3012f6[_0xd9e6('0x2d')]!==_0xd9e6('0x3c')){var _0x5f2f98={};_0x5f2f98[_0x3012f6['name']]={'$like':'%'+_0x105831['query'][_0xd9e6('0x3d')]+'%'};return _0x5f2f98;}})});}_0x3e98d6=_['merge']({},_0x3e98d6,_0x105831['options']);var _0x452b7b={'where':_0x3e98d6[_0xd9e6('0x3a')]};return db[_0xd9e6('0x2b')]['count'](_0x452b7b)[_0xd9e6('0x23')](function(_0x9d22ea){_0x3470f5[_0xd9e6('0x1b')]=_0x9d22ea;if(_0x105831['query'][_0xd9e6('0x3e')]){_0x3e98d6[_0xd9e6('0x3f')]=[{'all':!![]}];}return db[_0xd9e6('0x2b')][_0xd9e6('0x40')](_0x3e98d6);})[_0xd9e6('0x23')](function(_0x4b874e){_0x3470f5[_0xd9e6('0x41')]=_0x4b874e;return _0x3470f5;})['then'](respondWithFilteredResult(_0x2b2f4b,_0x3e98d6))['catch'](handleError(_0x2b2f4b,null));};exports['show']=function(_0xad2935,_0x101350){var _0x5f339f={'raw':!![],'where':{'id':_0xad2935[_0xd9e6('0x42')]['id']}},_0x2e3fa8={};_0x2e3fa8[_0xd9e6('0x2f')]=_[_0xd9e6('0x43')](db[_0xd9e6('0x2b')][_0xd9e6('0x44')]);_0x2e3fa8[_0xd9e6('0x30')]=_[_0xd9e6('0x43')](_0xad2935['query']);_0x2e3fa8[_0xd9e6('0x31')]=_[_0xd9e6('0x32')](_0x2e3fa8[_0xd9e6('0x2f')],_0x2e3fa8[_0xd9e6('0x30')]);_0x5f339f[_0xd9e6('0x34')]=_[_0xd9e6('0x32')](_0x2e3fa8[_0xd9e6('0x2f')],qs[_0xd9e6('0x33')](_0xad2935[_0xd9e6('0x30')]['fields']));_0x5f339f[_0xd9e6('0x34')]=_0x5f339f[_0xd9e6('0x34')][_0xd9e6('0x35')]?_0x5f339f[_0xd9e6('0x34')]:_0x2e3fa8[_0xd9e6('0x2f')];if(_0xad2935[_0xd9e6('0x30')][_0xd9e6('0x3e')]){_0x5f339f[_0xd9e6('0x3f')]=[{'all':!![]}];}_0x5f339f=_['merge']({},_0x5f339f,_0xad2935[_0xd9e6('0x45')]);return db[_0xd9e6('0x2b')][_0xd9e6('0x46')](_0x5f339f)[_0xd9e6('0x23')](handleEntityNotFound(_0x101350,null))[_0xd9e6('0x23')](respondWithResult(_0x101350,null))[_0xd9e6('0x47')](handleError(_0x101350,null));};exports[_0xd9e6('0x48')]=function(_0x1f2265,_0x1b9973){return db['WhatsappApplication'][_0xd9e6('0x48')](_0x1f2265[_0xd9e6('0x49')],{})[_0xd9e6('0x23')](respondWithResult(_0x1b9973,0xc9))['catch'](handleError(_0x1b9973,null));};exports[_0xd9e6('0x22')]=function(_0x324fe8,_0x14719a){if(_0x324fe8[_0xd9e6('0x49')]['id']){delete _0x324fe8[_0xd9e6('0x49')]['id'];}return db[_0xd9e6('0x2b')][_0xd9e6('0x46')]({'where':{'id':_0x324fe8[_0xd9e6('0x42')]['id']}})[_0xd9e6('0x23')](handleEntityNotFound(_0x14719a,null))[_0xd9e6('0x23')](saveUpdates(_0x324fe8[_0xd9e6('0x49')],null))['then'](respondWithResult(_0x14719a,null))['catch'](handleError(_0x14719a,null));};exports[_0xd9e6('0x24')]=function(_0x37ae2d,_0x3a3325){return db[_0xd9e6('0x2b')][_0xd9e6('0x46')]({'where':{'id':_0x37ae2d[_0xd9e6('0x42')]['id']}})['then'](handleEntityNotFound(_0x3a3325,null))[_0xd9e6('0x23')](removeEntity(_0x3a3325,null))['catch'](handleError(_0x3a3325,null));};
\ No newline at end of file