Built motion from commit 709aa6fb5ed03aa61bc373fcdbf622215d37d30b. Version 3.0.0...
[motion-next.git] / server / migrations / 2.3.5.js
1 const a977_0x4e0c=['enqueue','Added\x20column\x20%s\x20to\x20%s','prototype','addIndex\x20%s\x20%s\x20%s\x20[%s]','info','Removed\x20column\x20%s\x20from\x20%s','then','renameColumn','sequence','removeColumn','removeIndex','join','query\x20%s','indicesType','queryInterface','removeIndex\x20%s\x20%s','changeColumn','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','addIndex','finally','catch','inspect','stringify','exports','util','dropTable','query','addColumn','tail','migration','sequelize','../config/logger'];(function(_0x459dd9,_0x4e0c8e){const _0x3a5b08=function(_0x20a6c1){while(--_0x20a6c1){_0x459dd9['push'](_0x459dd9['shift']());}};_0x3a5b08(++_0x4e0c8e);}(a977_0x4e0c,0xc1));const a977_0x3a5b=function(_0x459dd9,_0x4e0c8e){_0x459dd9=_0x459dd9-0x0;let _0x3a5b08=a977_0x4e0c[_0x459dd9];return _0x3a5b08;};const _0x488b2a=a977_0x3a5b;'use strict';const util=require(_0x488b2a('0x17')),logger=require(_0x488b2a('0x1e'))(_0x488b2a('0x1c')),Sequence=function(){};Sequence[_0x488b2a('0x1')][_0x488b2a('0x1f')]=function(_0x20a6c1){const _0x156af7=_0x488b2a;this[_0x156af7('0x1b')]=this[_0x156af7('0x1b')]?this['tail'][_0x156af7('0x12')](_0x20a6c1):_0x20a6c1();};const Migration=function(_0x346f9f){const _0x356bc4=_0x488b2a;this[_0x356bc4('0xd')]=_0x346f9f,this['sequence']=new Sequence();};Migration[_0x488b2a('0x1')][_0x488b2a('0xf')]=function(_0x3b4e6f,_0xad3bdc,_0x53348e){const _0x2c4078=_0x488b2a,_0x9e9f8d=this;this[_0x2c4078('0x7')][_0x2c4078('0x1f')](function(){const _0x26d712=_0x2c4078;return _0x9e9f8d['queryInterface']['changeColumn'](_0x3b4e6f,_0xad3bdc,_0x53348e)[_0x26d712('0x5')](function(){const _0x12c7bd=_0x26d712;logger[_0x12c7bd('0x3')]('Changed\x20column\x20%s\x20in\x20table\x20%s',_0xad3bdc,_0x3b4e6f);})[_0x26d712('0x13')](function(_0x46640e){const _0x39fe1c=_0x26d712;logger[_0x39fe1c('0x3')](JSON[_0x39fe1c('0x15')](_0x46640e));});});},Migration['prototype'][_0x488b2a('0x1a')]=function(_0x27cd41,_0x53d3b0,_0x101815){const _0x404531=_0x488b2a,_0x59c46a=this;this[_0x404531('0x7')]['enqueue'](function(){const _0x53152a=_0x404531;return _0x59c46a[_0x53152a('0xd')][_0x53152a('0x1a')](_0x27cd41,_0x53d3b0,_0x101815)['then'](function(){const _0x22cad7=_0x53152a;logger['info'](_0x22cad7('0x0'),_0x53d3b0,_0x27cd41);})[_0x53152a('0x13')](function(_0x4cda22){const _0x46cb4d=_0x53152a;logger[_0x46cb4d('0x3')](JSON[_0x46cb4d('0x15')](_0x4cda22));});});},Migration[_0x488b2a('0x1')]['dropTable']=function(_0x25606b){const _0x3efa34=_0x488b2a,_0x5e908a=this;this['sequence'][_0x3efa34('0x1f')](function(){const _0x2f4a47=_0x3efa34;return _0x5e908a['queryInterface'][_0x2f4a47('0x18')](_0x25606b,{'force':!![]})[_0x2f4a47('0x5')](function(){const _0x4a6ec3=_0x2f4a47;logger[_0x4a6ec3('0x3')]('table\x20dropped\x20%s',_0x25606b);})['catch'](function(_0x56370a){const _0x587c83=_0x2f4a47;logger[_0x587c83('0x3')](JSON['stringify'](_0x56370a));});});},Migration[_0x488b2a('0x1')][_0x488b2a('0x11')]=function(_0x1bee0c,_0xac531f,_0x1102f0){const _0x42d67f=_0x488b2a,_0x17be7b=this;this[_0x42d67f('0x7')][_0x42d67f('0x1f')](function(){const _0x1a0756=_0x42d67f;return _0x17be7b[_0x1a0756('0xd')][_0x1a0756('0x11')](_0x1bee0c,_0xac531f,{'indexName':_0x1102f0['indexName'],'indicesType':_0x1102f0[_0x1a0756('0xc')]})[_0x1a0756('0x5')](function(){const _0x583889=_0x1a0756;logger[_0x583889('0x3')](_0x583889('0x2'),_0x1bee0c,_0xac531f[_0x583889('0xa')](','),_0x1102f0['indexName'],_0x1102f0[_0x583889('0xc')]);})[_0x1a0756('0x13')](function(_0xdefb54){const _0x4d9798=_0x1a0756;logger[_0x4d9798('0x3')](JSON[_0x4d9798('0x15')](_0xdefb54));});});},Migration[_0x488b2a('0x1')][_0x488b2a('0x9')]=function(_0x5a2346,_0xdf9ac2){const _0x525566=_0x488b2a,_0x1569fd=this;this[_0x525566('0x7')][_0x525566('0x1f')](function(){const _0x2699b0=_0x525566;return _0x1569fd[_0x2699b0('0xd')][_0x2699b0('0x9')](_0x5a2346,_0xdf9ac2)[_0x2699b0('0x5')](function(){const _0x1d0016=_0x2699b0;logger['info'](_0x1d0016('0xe'),_0x5a2346,_0xdf9ac2);})[_0x2699b0('0x13')](function(_0x3a21ef){const _0x4e9de7=_0x2699b0;logger[_0x4e9de7('0x3')](JSON[_0x4e9de7('0x15')](_0x3a21ef));});});},Migration['prototype'][_0x488b2a('0x19')]=function(_0xe1ac72){const _0x4c1e5e=_0x488b2a,_0x1c2678=this;this['sequence'][_0x4c1e5e('0x1f')](function(){const _0x4a89f2=_0x4c1e5e;return _0x1c2678[_0x4a89f2('0xd')][_0x4a89f2('0x1d')][_0x4a89f2('0x19')](_0xe1ac72)[_0x4a89f2('0x5')](function(){const _0x1d2819=_0x4a89f2;logger['info'](_0x1d2819('0xb'),_0xe1ac72);})[_0x4a89f2('0x13')](function(_0x1976fe){const _0x559da4=_0x4a89f2;logger['info'](JSON[_0x559da4('0x15')](_0x1976fe));});});},Migration['prototype'][_0x488b2a('0x8')]=function(_0x9618c2,_0x21dfc1){const _0x3d5a7d=_0x488b2a,_0x4b602f=this;this[_0x3d5a7d('0x7')][_0x3d5a7d('0x1f')](function(){const _0x576a59=_0x3d5a7d;return _0x4b602f[_0x576a59('0xd')]['removeColumn'](_0x9618c2,_0x21dfc1)['then'](function(){const _0x150fa6=_0x576a59;logger[_0x150fa6('0x3')](_0x150fa6('0x4'),_0x21dfc1,_0x9618c2);})[_0x576a59('0x13')](function(_0x1ab87f){const _0x113ea9=_0x576a59;logger['info'](util[_0x113ea9('0x14')](_0x1ab87f,{'showHidden':![],'depth':null}));});});},Migration[_0x488b2a('0x1')][_0x488b2a('0x6')]=function(_0x4ea641,_0x1b7486,_0x155fb4){const _0x46af5c=_0x488b2a,_0x5a1158=this;this['sequence'][_0x46af5c('0x1f')](function(){const _0x422a8c=_0x46af5c;return _0x5a1158[_0x422a8c('0xd')][_0x422a8c('0x6')](_0x4ea641,_0x1b7486,_0x155fb4)[_0x422a8c('0x5')](function(){const _0x2cbc63=_0x422a8c;logger[_0x2cbc63('0x3')](_0x2cbc63('0x10'),_0x1b7486,_0x155fb4,_0x4ea641);})[_0x422a8c('0x13')](function(_0x57b027){const _0xd1d988=_0x422a8c;logger[_0xd1d988('0x3')](util[_0xd1d988('0x14')](_0x57b027,{'showHidden':![],'depth':null}));});});},Migration['prototype']['final']=function(_0x5abfef){const _0xa9805a=_0x488b2a;this['sequence'][_0xa9805a('0x1f')](function(){return _0x5abfef();});},module[_0x488b2a('0x16')]={'up':function(_0x2e8fbd){return new Promise(function(_0x5d48bb){const _0x4171ce=new Migration(_0x2e8fbd);_0x4171ce['final'](_0x5d48bb);});},'down':function(){}};