Built motion from commit ecf5ab8ec560fd4c6972692268e350fcef2f38e7. Version 3.0.0...
[motion-next.git] / server / migrations / 2.0.75.js
1 const a954_0x3cfc=['query\x20%s','catch','removeIndex\x20%s\x20%s','then','info','queryInterface','Changed\x20column\x20%s\x20in\x20table\x20%s','Added\x20column\x20%s\x20to\x20%s','addColumn','final','join','migration','tail','dropTable','removeColumn','changeColumn','finally','inspect','removeIndex','prototype','enqueue','../config/logger','renameColumn','query','stringify','table\x20dropped\x20%s','addIndex','sequence'];(function(_0x4f89ef,_0x3cfcd9){const _0x1547d9=function(_0x417b8f){while(--_0x417b8f){_0x4f89ef['push'](_0x4f89ef['shift']());}};_0x1547d9(++_0x3cfcd9);}(a954_0x3cfc,0xca));const a954_0x1547=function(_0x4f89ef,_0x3cfcd9){_0x4f89ef=_0x4f89ef-0x0;let _0x1547d9=a954_0x3cfc[_0x4f89ef];return _0x1547d9;};const _0xd10b3e=a954_0x1547;'use strict';const util=require('util'),logger=require(_0xd10b3e('0xf'))(_0xd10b3e('0x5')),Sequence=function(){};Sequence['prototype'][_0xd10b3e('0xe')]=function(_0x417b8f){const _0x522905=_0xd10b3e;this[_0x522905('0x6')]=this[_0x522905('0x6')]?this['tail'][_0x522905('0xa')](_0x417b8f):_0x417b8f();};const Migration=function(_0x52676d){const _0x429bb5=_0xd10b3e;this[_0x429bb5('0x1b')]=_0x52676d,this[_0x429bb5('0x15')]=new Sequence();};Migration[_0xd10b3e('0xd')]['changeColumn']=function(_0x1b7512,_0x4e72cb,_0x355128){const _0x48fafe=_0xd10b3e,_0x228b04=this;this[_0x48fafe('0x15')][_0x48fafe('0xe')](function(){const _0x7990e6=_0x48fafe;return _0x228b04[_0x7990e6('0x1b')][_0x7990e6('0x9')](_0x1b7512,_0x4e72cb,_0x355128)['then'](function(){const _0x27b231=_0x7990e6;logger[_0x27b231('0x1a')](_0x27b231('0x0'),_0x4e72cb,_0x1b7512);})[_0x7990e6('0x17')](function(_0x3b44e9){const _0x45f5a1=_0x7990e6;logger[_0x45f5a1('0x1a')](JSON[_0x45f5a1('0x12')](_0x3b44e9));});});},Migration[_0xd10b3e('0xd')][_0xd10b3e('0x2')]=function(_0x1321cc,_0x57c8b6,_0x28f6ba){const _0x4a5c83=_0xd10b3e,_0x30372a=this;this['sequence'][_0x4a5c83('0xe')](function(){const _0x5d678c=_0x4a5c83;return _0x30372a[_0x5d678c('0x1b')][_0x5d678c('0x2')](_0x1321cc,_0x57c8b6,_0x28f6ba)[_0x5d678c('0x19')](function(){const _0x534a43=_0x5d678c;logger[_0x534a43('0x1a')](_0x534a43('0x1'),_0x57c8b6,_0x1321cc);})[_0x5d678c('0x17')](function(_0x1aa2fd){const _0x28e804=_0x5d678c;logger[_0x28e804('0x1a')](JSON[_0x28e804('0x12')](_0x1aa2fd));});});},Migration[_0xd10b3e('0xd')][_0xd10b3e('0x7')]=function(_0x37189c){const _0x59cf4e=_0xd10b3e,_0x5b434f=this;this[_0x59cf4e('0x15')][_0x59cf4e('0xe')](function(){const _0x5f3e80=_0x59cf4e;return _0x5b434f[_0x5f3e80('0x1b')][_0x5f3e80('0x7')](_0x37189c,{'force':!![]})[_0x5f3e80('0x19')](function(){const _0x57bcc9=_0x5f3e80;logger['info'](_0x57bcc9('0x13'),_0x37189c);})[_0x5f3e80('0x17')](function(_0x9d29d8){logger['info'](JSON['stringify'](_0x9d29d8));});});},Migration[_0xd10b3e('0xd')][_0xd10b3e('0x14')]=function(_0x381555,_0x52fd63,_0x57cfd8){const _0x16d083=_0xd10b3e,_0x4f6002=this;this['sequence'][_0x16d083('0xe')](function(){const _0xc9d0ea=_0x16d083;return _0x4f6002[_0xc9d0ea('0x1b')][_0xc9d0ea('0x14')](_0x381555,_0x52fd63,{'indexName':_0x57cfd8})[_0xc9d0ea('0x19')](function(){const _0x138bc5=_0xc9d0ea;logger['info']('addIndex\x20%s\x20%s\x20%s',_0x381555,_0x52fd63[_0x138bc5('0x4')](','),_0x57cfd8);})['catch'](function(_0x439619){const _0x4b9029=_0xc9d0ea;logger[_0x4b9029('0x1a')](JSON[_0x4b9029('0x12')](_0x439619));});});},Migration[_0xd10b3e('0xd')][_0xd10b3e('0xc')]=function(_0x452a79,_0x35d5e2){const _0x49d356=_0xd10b3e,_0x55b857=this;this[_0x49d356('0x15')][_0x49d356('0xe')](function(){const _0x3c42e7=_0x49d356;return _0x55b857['queryInterface'][_0x3c42e7('0xc')](_0x452a79,_0x35d5e2)['then'](function(){const _0x561a60=_0x3c42e7;logger['info'](_0x561a60('0x18'),_0x452a79,_0x35d5e2);})[_0x3c42e7('0x17')](function(_0x12f127){const _0x144988=_0x3c42e7;logger['info'](JSON[_0x144988('0x12')](_0x12f127));});});},Migration[_0xd10b3e('0xd')]['query']=function(_0x5d9c39){const _0x766676=_0xd10b3e,_0x2343d7=this;this[_0x766676('0x15')][_0x766676('0xe')](function(){const _0x9463f1=_0x766676;return _0x2343d7['queryInterface']['sequelize'][_0x9463f1('0x11')](_0x5d9c39)[_0x9463f1('0x19')](function(){const _0x588afd=_0x9463f1;logger['info'](_0x588afd('0x16'),_0x5d9c39);})[_0x9463f1('0x17')](function(_0x29693d){const _0x95b8b2=_0x9463f1;logger['info'](JSON[_0x95b8b2('0x12')](_0x29693d));});});},Migration[_0xd10b3e('0xd')][_0xd10b3e('0x8')]=function(_0x24122c,_0x1ca101){const _0x1d880d=_0xd10b3e,_0x455570=this;this['sequence'][_0x1d880d('0xe')](function(){const _0x43abfd=_0x1d880d;return _0x455570[_0x43abfd('0x1b')][_0x43abfd('0x8')](_0x24122c,_0x1ca101)['then'](function(){const _0x549fb0=_0x43abfd;logger[_0x549fb0('0x1a')]('Removed\x20column\x20%s\x20from\x20%s',_0x1ca101,_0x24122c);})[_0x43abfd('0x17')](function(_0x417bec){logger['info'](util['inspect'](_0x417bec,{'showHidden':![],'depth':null}));});});},Migration['prototype'][_0xd10b3e('0x10')]=function(_0x1b99d6,_0x206fd8,_0x433606){const _0x25d840=_0xd10b3e,_0x378dce=this;this[_0x25d840('0x15')][_0x25d840('0xe')](function(){const _0x40ad35=_0x25d840;return _0x378dce[_0x40ad35('0x1b')][_0x40ad35('0x10')](_0x1b99d6,_0x206fd8,_0x433606)[_0x40ad35('0x19')](function(){const _0x301ea2=_0x40ad35;logger[_0x301ea2('0x1a')]('Renamed\x20column\x20from\x20%s\x20to\x20%s\x20on\x20%s',_0x206fd8,_0x433606,_0x1b99d6);})[_0x40ad35('0x17')](function(_0x214537){const _0x5cccd9=_0x40ad35;logger[_0x5cccd9('0x1a')](util[_0x5cccd9('0xb')](_0x214537,{'showHidden':![],'depth':null}));});});},Migration[_0xd10b3e('0xd')]['final']=function(_0x5f1858){const _0x13aa01=_0xd10b3e;this['sequence'][_0x13aa01('0xe')](function(){return _0x5f1858();});},module['exports']={'up':function(_0x2f0db6){return new Promise(function(_0x187306){const _0x444498=a954_0x1547,_0x28b66f=new Migration(_0x2f0db6);_0x28b66f[_0x444498('0x3')](_0x187306);});},'down':function(){}};