58d7a60e6d558e856d2be1f68846de7d7a1e3ea8
[motion-next.git] / server / migrations / 2.3.4.js
1 const a1141_0x3c9b=['removeIndex','sequence','final','removeColumn','then','info','Changed\x20column\x20%s\x20in\x20table\x20%s','Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s','util','finally','addIndex','dropTable','enqueue','../config/logger','Added\x20column\x20%s\x20to\x20%s','Removed\x20column\x20%s\x20from\x20%s','renameColumn','catch','tail','join','changeColumn','addIndex\x20%s\x20%s\x20%s','inspect','stringify','prototype','query','exports','migration','addColumn','query\x20%s','queryInterface'];(function(_0x26d3bf,_0x4d08b6){const _0x3c9be8=function(_0x3cb192){while(--_0x3cb192){_0x26d3bf['push'](_0x26d3bf['shift']());}};_0x3c9be8(++_0x4d08b6);}(a1141_0x3c9b,0x1ee));const a1141_0x3cb1=function(_0x26d3bf,_0x4d08b6){_0x26d3bf=_0x26d3bf-0x16c;let _0x3c9be8=a1141_0x3c9b[_0x26d3bf];return _0x3c9be8;};const a1141_0x588ed9=a1141_0x3cb1;'use strict';const util=require(a1141_0x588ed9(0x176)),logger=require(a1141_0x588ed9(0x17b))(a1141_0x588ed9(0x189)),Sequence=function(){};Sequence[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x17a)]=function(_0x1f6d4f){const _0x2f000a=a1141_0x588ed9;this[_0x2f000a(0x180)]=this[_0x2f000a(0x180)]?this[_0x2f000a(0x180)][_0x2f000a(0x177)](_0x1f6d4f):_0x1f6d4f();};const Migration=function(_0x7e343d){this['queryInterface']=_0x7e343d,this['sequence']=new Sequence();};Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x182)]=function(_0x5e423c,_0x144664,_0x3b57be){const _0x44aaa5=a1141_0x588ed9,_0x3b1254=this;this[_0x44aaa5(0x16f)][_0x44aaa5(0x17a)](function(){const _0x3f5fa5=_0x44aaa5;return _0x3b1254[_0x3f5fa5(0x16d)]['changeColumn'](_0x5e423c,_0x144664,_0x3b57be)[_0x3f5fa5(0x172)](function(){const _0x519aa8=_0x3f5fa5;logger[_0x519aa8(0x173)](_0x519aa8(0x174),_0x144664,_0x5e423c);})['catch'](function(_0x27f4ce){const _0x328874=_0x3f5fa5;logger[_0x328874(0x173)](JSON[_0x328874(0x185)](_0x27f4ce));});});},Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x18a)]=function(_0x328429,_0x4d4325,_0x5631aa){const _0x392528=a1141_0x588ed9,_0xf39ce1=this;this[_0x392528(0x16f)][_0x392528(0x17a)](function(){const _0x509959=_0x392528;return _0xf39ce1[_0x509959(0x16d)][_0x509959(0x18a)](_0x328429,_0x4d4325,_0x5631aa)[_0x509959(0x172)](function(){const _0xcb3aaa=_0x509959;logger['info'](_0xcb3aaa(0x17c),_0x4d4325,_0x328429);})[_0x509959(0x17f)](function(_0x5042af){const _0x32b65a=_0x509959;logger[_0x32b65a(0x173)](JSON[_0x32b65a(0x185)](_0x5042af));});});},Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x179)]=function(_0x5c5a9b){const _0x1bffbc=a1141_0x588ed9,_0x261eee=this;this['sequence'][_0x1bffbc(0x17a)](function(){const _0x4a956d=_0x1bffbc;return _0x261eee['queryInterface'][_0x4a956d(0x179)](_0x5c5a9b,{'force':!![]})[_0x4a956d(0x172)](function(){const _0xaf7b=_0x4a956d;logger[_0xaf7b(0x173)]('table\x20dropped\x20%s',_0x5c5a9b);})[_0x4a956d(0x17f)](function(_0x54fa2a){const _0x33d223=_0x4a956d;logger[_0x33d223(0x173)](JSON[_0x33d223(0x185)](_0x54fa2a));});});},Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x178)]=function(_0x3bb780,_0x297d94,_0x553ad4){const _0x1f2b8d=a1141_0x588ed9,_0x3c6e39=this;this['sequence'][_0x1f2b8d(0x17a)](function(){const _0x3ed576=_0x1f2b8d;return _0x3c6e39[_0x3ed576(0x16d)][_0x3ed576(0x178)](_0x3bb780,_0x297d94,{'indexName':_0x553ad4})['then'](function(){const _0x376be9=_0x3ed576;logger[_0x376be9(0x173)](_0x376be9(0x183),_0x3bb780,_0x297d94[_0x376be9(0x181)](','),_0x553ad4);})[_0x3ed576(0x17f)](function(_0x2c6a4e){const _0x127204=_0x3ed576;logger[_0x127204(0x173)](JSON[_0x127204(0x185)](_0x2c6a4e));});});},Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x16e)]=function(_0x3aae7b,_0x13ae3d){const _0x61391c=a1141_0x588ed9,_0x4aa0c8=this;this[_0x61391c(0x16f)][_0x61391c(0x17a)](function(){const _0x22ceff=_0x61391c;return _0x4aa0c8[_0x22ceff(0x16d)][_0x22ceff(0x16e)](_0x3aae7b,_0x13ae3d)[_0x22ceff(0x172)](function(){logger['info']('removeIndex\x20%s\x20%s',_0x3aae7b,_0x13ae3d);})[_0x22ceff(0x17f)](function(_0x3a655c){const _0x4b679a=_0x22ceff;logger['info'](JSON[_0x4b679a(0x185)](_0x3a655c));});});},Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x187)]=function(_0x34e77e){const _0x39d26b=a1141_0x588ed9,_0x2b808c=this;this[_0x39d26b(0x16f)][_0x39d26b(0x17a)](function(){const _0xb3e8f9=_0x39d26b;return _0x2b808c[_0xb3e8f9(0x16d)]['sequelize'][_0xb3e8f9(0x187)](_0x34e77e)['then'](function(){const _0x482e6c=_0xb3e8f9;logger[_0x482e6c(0x173)](_0x482e6c(0x16c),_0x34e77e);})['catch'](function(_0x427068){const _0x35f618=_0xb3e8f9;logger['info'](JSON[_0x35f618(0x185)](_0x427068));});});},Migration['prototype'][a1141_0x588ed9(0x171)]=function(_0x42cf25,_0x20e883){const _0x53ae38=a1141_0x588ed9,_0x22bc5c=this;this[_0x53ae38(0x16f)][_0x53ae38(0x17a)](function(){const _0x3a3418=_0x53ae38;return _0x22bc5c[_0x3a3418(0x16d)][_0x3a3418(0x171)](_0x42cf25,_0x20e883)[_0x3a3418(0x172)](function(){const _0x180131=_0x3a3418;logger[_0x180131(0x173)](_0x180131(0x17d),_0x20e883,_0x42cf25);})[_0x3a3418(0x17f)](function(_0x29a549){const _0x9a9436=_0x3a3418;logger['info'](util[_0x9a9436(0x184)](_0x29a549,{'showHidden':![],'depth':null}));});});},Migration['prototype'][a1141_0x588ed9(0x17e)]=function(_0x215094,_0x3f5049,_0x35ac42){const _0x58a12b=a1141_0x588ed9,_0x38773a=this;this['sequence'][_0x58a12b(0x17a)](function(){const _0x1a134b=_0x58a12b;return _0x38773a[_0x1a134b(0x16d)][_0x1a134b(0x17e)](_0x215094,_0x3f5049,_0x35ac42)[_0x1a134b(0x172)](function(){const _0x3da757=_0x1a134b;logger['info'](_0x3da757(0x175),_0x3f5049,_0x35ac42,_0x215094);})[_0x1a134b(0x17f)](function(_0x216182){const _0x2b8619=_0x1a134b;logger[_0x2b8619(0x173)](util[_0x2b8619(0x184)](_0x216182,{'showHidden':![],'depth':null}));});});},Migration[a1141_0x588ed9(0x186)][a1141_0x588ed9(0x170)]=function(_0x23343f){const _0x578fa5=a1141_0x588ed9;this[_0x578fa5(0x16f)][_0x578fa5(0x17a)](function(){return _0x23343f();});},module[a1141_0x588ed9(0x188)]={'up':function(_0x38016a){return new Promise(function(_0x560935){const _0x2a0ea3=new Migration(_0x38016a);_0x2a0ea3['final'](_0x560935);});},'down':function(){}};