Built motion from commit bfc7a72f7045b27461c9a5d1f71c1a658cfd0b8b. Version 3.0.0...
[motion-next.git] / server / migrations / 2.3.5.js
1 const a978_0x3f28=['final','removeIndex\x20%s\x20%s','addIndex','prototype','tail','exports','finally','Added\x20column\x20%s\x20to\x20%s','join','then','addColumn','indicesType','enqueue','dropTable','query\x20%s','info','table\x20dropped\x20%s','indexName','stringify','inspect','migration','query','catch','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','Removed\x20column\x20%s\x20from\x20%s','removeIndex','Changed\x20column\x20%s\x20in\x20table\x20%s','queryInterface','sequence','renameColumn','changeColumn'];(function(_0x33f906,_0x3f28cd){const _0x332dba=function(_0x1ffc4d){while(--_0x1ffc4d){_0x33f906['push'](_0x33f906['shift']());}};_0x332dba(++_0x3f28cd);}(a978_0x3f28,0xa4));const a978_0x332d=function(_0x33f906,_0x3f28cd){_0x33f906=_0x33f906-0x0;let _0x332dba=a978_0x3f28[_0x33f906];return _0x332dba;};const _0x32b72e=a978_0x332d;'use strict';const util=require('util'),logger=require('../config/logger')(_0x32b72e('0xb')),Sequence=function(){};Sequence[_0x32b72e('0x19')]['enqueue']=function(_0x1ffc4d){const _0x274a11=_0x32b72e;this[_0x274a11('0x1a')]=this[_0x274a11('0x1a')]?this[_0x274a11('0x1a')][_0x274a11('0x1c')](_0x1ffc4d):_0x1ffc4d();};const Migration=function(_0x5c69c2){const _0x40433e=_0x32b72e;this[_0x40433e('0x12')]=_0x5c69c2,this['sequence']=new Sequence();};Migration[_0x32b72e('0x19')][_0x32b72e('0x15')]=function(_0x48009b,_0xb8bc1c,_0x55bdf2){const _0x39345a=_0x32b72e,_0x183c8a=this;this[_0x39345a('0x13')][_0x39345a('0x3')](function(){const _0x23f5c0=_0x39345a;return _0x183c8a[_0x23f5c0('0x12')]['changeColumn'](_0x48009b,_0xb8bc1c,_0x55bdf2)[_0x23f5c0('0x0')](function(){const _0xebb0fc=_0x23f5c0;logger[_0xebb0fc('0x6')](_0xebb0fc('0x11'),_0xb8bc1c,_0x48009b);})[_0x23f5c0('0xd')](function(_0x27c203){const _0x5e0c5d=_0x23f5c0;logger[_0x5e0c5d('0x6')](JSON[_0x5e0c5d('0x9')](_0x27c203));});});},Migration['prototype'][_0x32b72e('0x1')]=function(_0x3d56a9,_0x4d1362,_0x5cb0b1){const _0x5ce385=_0x32b72e,_0x35d2b6=this;this['sequence'][_0x5ce385('0x3')](function(){const _0x25ab75=_0x5ce385;return _0x35d2b6['queryInterface'][_0x25ab75('0x1')](_0x3d56a9,_0x4d1362,_0x5cb0b1)['then'](function(){const _0x5b106a=_0x25ab75;logger[_0x5b106a('0x6')](_0x5b106a('0x1d'),_0x4d1362,_0x3d56a9);})[_0x25ab75('0xd')](function(_0x46314f){const _0xfb56ca=_0x25ab75;logger[_0xfb56ca('0x6')](JSON[_0xfb56ca('0x9')](_0x46314f));});});},Migration[_0x32b72e('0x19')][_0x32b72e('0x4')]=function(_0x393894){const _0x3e731a=_0x32b72e,_0x248ef5=this;this[_0x3e731a('0x13')]['enqueue'](function(){const _0x3a05fc=_0x3e731a;return _0x248ef5[_0x3a05fc('0x12')][_0x3a05fc('0x4')](_0x393894,{'force':!![]})[_0x3a05fc('0x0')](function(){const _0x54143f=_0x3a05fc;logger[_0x54143f('0x6')](_0x54143f('0x7'),_0x393894);})[_0x3a05fc('0xd')](function(_0x518a68){const _0x5a70e9=_0x3a05fc;logger['info'](JSON[_0x5a70e9('0x9')](_0x518a68));});});},Migration[_0x32b72e('0x19')][_0x32b72e('0x18')]=function(_0x2c12be,_0x373e00,_0x552bcc){const _0x426d14=_0x32b72e,_0x11f620=this;this[_0x426d14('0x13')][_0x426d14('0x3')](function(){const _0x279533=_0x426d14;return _0x11f620[_0x279533('0x12')][_0x279533('0x18')](_0x2c12be,_0x373e00,{'indexName':_0x552bcc['indexName'],'indicesType':_0x552bcc['indicesType']})[_0x279533('0x0')](function(){const _0x403e57=_0x279533;logger[_0x403e57('0x6')]('addIndex\x20%s\x20%s\x20%s\x20[%s]',_0x2c12be,_0x373e00[_0x403e57('0x1e')](','),_0x552bcc[_0x403e57('0x8')],_0x552bcc[_0x403e57('0x2')]);})[_0x279533('0xd')](function(_0x29c87f){const _0x242393=_0x279533;logger[_0x242393('0x6')](JSON[_0x242393('0x9')](_0x29c87f));});});},Migration['prototype']['removeIndex']=function(_0x478ecf,_0x4eea8e){const _0xbb1e6d=_0x32b72e,_0x5f0a46=this;this[_0xbb1e6d('0x13')][_0xbb1e6d('0x3')](function(){const _0x2255ec=_0xbb1e6d;return _0x5f0a46['queryInterface'][_0x2255ec('0x10')](_0x478ecf,_0x4eea8e)[_0x2255ec('0x0')](function(){const _0x2aa56a=_0x2255ec;logger[_0x2aa56a('0x6')](_0x2aa56a('0x17'),_0x478ecf,_0x4eea8e);})[_0x2255ec('0xd')](function(_0x558c93){const _0x2d4cf4=_0x2255ec;logger[_0x2d4cf4('0x6')](JSON[_0x2d4cf4('0x9')](_0x558c93));});});},Migration['prototype'][_0x32b72e('0xc')]=function(_0x2843ad){const _0x4bcb2e=_0x32b72e,_0x524448=this;this[_0x4bcb2e('0x13')][_0x4bcb2e('0x3')](function(){const _0x2c1ad7=_0x4bcb2e;return _0x524448[_0x2c1ad7('0x12')]['sequelize'][_0x2c1ad7('0xc')](_0x2843ad)[_0x2c1ad7('0x0')](function(){const _0x183c12=_0x2c1ad7;logger[_0x183c12('0x6')](_0x183c12('0x5'),_0x2843ad);})['catch'](function(_0x3ce26e){const _0x5e7217=_0x2c1ad7;logger[_0x5e7217('0x6')](JSON['stringify'](_0x3ce26e));});});},Migration[_0x32b72e('0x19')]['removeColumn']=function(_0x4bed32,_0x2bdf90){const _0x2fd28f=_0x32b72e,_0x56b8cf=this;this[_0x2fd28f('0x13')][_0x2fd28f('0x3')](function(){const _0x380495=_0x2fd28f;return _0x56b8cf['queryInterface']['removeColumn'](_0x4bed32,_0x2bdf90)[_0x380495('0x0')](function(){const _0x8ec964=_0x380495;logger[_0x8ec964('0x6')](_0x8ec964('0xf'),_0x2bdf90,_0x4bed32);})[_0x380495('0xd')](function(_0x586db6){const _0x249503=_0x380495;logger[_0x249503('0x6')](util[_0x249503('0xa')](_0x586db6,{'showHidden':![],'depth':null}));});});},Migration[_0x32b72e('0x19')][_0x32b72e('0x14')]=function(_0x332b01,_0x4bd95b,_0x4bc5c2){const _0x1c976c=_0x32b72e,_0x387d1=this;this[_0x1c976c('0x13')][_0x1c976c('0x3')](function(){const _0x2b2400=_0x1c976c;return _0x387d1['queryInterface'][_0x2b2400('0x14')](_0x332b01,_0x4bd95b,_0x4bc5c2)[_0x2b2400('0x0')](function(){const _0x2caaa5=_0x2b2400;logger[_0x2caaa5('0x6')](_0x2caaa5('0xe'),_0x4bd95b,_0x4bc5c2,_0x332b01);})[_0x2b2400('0xd')](function(_0x280910){const _0x35e2b3=_0x2b2400;logger[_0x35e2b3('0x6')](util[_0x35e2b3('0xa')](_0x280910,{'showHidden':![],'depth':null}));});});},Migration[_0x32b72e('0x19')]['final']=function(_0x5a76de){const _0x21447a=_0x32b72e;this[_0x21447a('0x13')]['enqueue'](function(){return _0x5a76de();});},module[_0x32b72e('0x1b')]={'up':function(_0x567a9d){return new Promise(function(_0x467c59){const _0x49be09=a978_0x332d,_0x4db425=new Migration(_0x567a9d);_0x4db425[_0x49be09('0x16')](_0x467c59);});},'down':function(){}};