config invocation handler: fix setting config values to null

Also correctly convert objects to string
This commit is contained in:
Adam
2018-06-01 22:14:27 -04:00
parent 3e624aba65
commit 1fb114b610

View File

@@ -112,7 +112,15 @@ class ConfigInvocationHandler implements InvocationHandler
}
}
manager.setConfiguration(group.keyName(), item.keyName(), args[0].toString());
if (newValue == null)
{
manager.unsetConfiguration(group.keyName(), item.keyName());
}
else
{
String newValueStr = ConfigManager.objectToString(newValue);
manager.setConfiguration(group.keyName(), item.keyName(), newValueStr);
}
return null;
}
}