fix: config migration
This commit is contained in:
parent
c346f0b8e4
commit
893e0b1493
1 changed files with 6 additions and 6 deletions
|
|
@ -6,12 +6,12 @@ const { migrate } = require('../lib/config-migration')
|
|||
|
||||
module.exports.up = function (next) {
|
||||
function migrateConfig(settings) {
|
||||
return migrate(settings.config, settings.accounts)
|
||||
.then(newSettings => Promise.all([
|
||||
saveConfig(newSettings.config),
|
||||
saveAccounts(newSettings.accounts)
|
||||
]))
|
||||
.then(() => next())
|
||||
const newSettings = migrate(settings.config, settings.accounts)
|
||||
return Promise.all([
|
||||
saveConfig(newSettings.config),
|
||||
saveAccounts(newSettings.accounts)
|
||||
])
|
||||
.then(() => next())
|
||||
}
|
||||
|
||||
settingsLoader.loadLatest(false)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue