fix: modules non-string config + live trail logging

This commit is contained in:
Nicolas Giard
2018-09-30 14:20:26 -04:00
parent 32a537ec06
commit 904e2a6efb
18 changed files with 141 additions and 37 deletions

View File

@@ -68,7 +68,7 @@ module.exports = {
await WIKI.models.authentication.query().patch({
isEnabled: str.isEnabled,
config: _.reduce(str.config, (result, value, key) => {
_.set(result, `${value.key}.value`, value.value)
_.set(result, `${value.key}`, _.get(JSON.parse(value.value), 'v', null))
return result
}, {}),
selfRegistration: str.selfRegistration,