fix: issue with 1645459054117-default-timezone

This commit is contained in:
Nikola Ubavic 2022-07-08 10:05:17 +02:00
parent 2d5cbe771a
commit d6305e456f

View file

@ -0,0 +1,20 @@
const { saveConfig, loadLatest } = require('../lib/new-settings-loader')
exports.up = function (next) {
const newConfig = {}
return loadLatest()
.then(config => {
if (config.config.locale_timezone === "0:0") {
newConfig[`locale_timezone`] = 'GMT'
return saveConfig(newConfig)
}
})
.then(next)
.catch(err => {
return next(err)
})
}
module.exports.down = function (next) {
next()
}