refuse to update a setting if it is gui only

This commit is contained in:
Stephen Birarda 2015-05-11 13:49:35 -07:00
parent 5afb0792dc
commit 55338a2b0f

View file

@ -258,6 +258,7 @@ bool DomainServerSettingsManager::settingExists(const QString& groupName, const
void DomainServerSettingsManager::updateSetting(const QString& key, const QJsonValue& newValue, QVariantMap& settingMap,
const QJsonObject& settingDescription) {
if (!settingDescription[VALUE_GUI_ONLY_FLAG_KEY].toBool()) {
if (newValue.isString()) {
if (newValue.toString().isEmpty()) {
// this is an empty value, clear it in settings variant so the default is sent
@ -315,6 +316,7 @@ void DomainServerSettingsManager::updateSetting(const QString& key, const QJsonV
// TODO: we still need to recurse here with the description in case values in the array have special types
settingMap[key] = newValue.toArray().toVariantList();
}
}
}
void DomainServerSettingsManager::recurseJSONObjectAndOverwriteSettings(const QJsonObject& postedObject,