Fixed location of showClassNames
Kevin Lyles [12-15-09 - 07:23]
Fixed location of showClassNames
diff --git a/Upgrade.lua b/Upgrade.lua
index 4097f46..4938d50 100644
--- a/Upgrade.lua
+++ b/Upgrade.lua
@@ -135,6 +135,20 @@ function noop_major_up(vars)
return vars
end
+function upgradeAccountToCorrectShowClassNames(vars)
+ if vars.options.tooltip.showClassNames == nil then
+ if vars.options.showClassNames == nil then
+ vars.options.tooltip.showClassNames = "Others"
+ else
+ vars.options.tooltip.showClassNames = vars.options.showClassNames
+ end
+ end
+ vars.options.showClassNames = nil
+
+ vars.dataMinorVersion = 2
+ return vars
+end
+
function upgradeAccountToBetterMetaEffectNames(vars)
local newName
local conversion = {
@@ -500,6 +514,7 @@ upgradeAccountFunctions = {
},
[1] = {
[0] = function(vars) return upgradeAccountToBetterMetaEffectNames(vars) end,
+ [1] = function(vars) return upgradeAccountToCorrectShowClassNames(vars) end,
},
}
@@ -518,6 +533,7 @@ downgradeAccountFunctions = {
[1] = {
[0] = downgradeAccountToDevelopment,
[1] = downgradeAccountFromBetterMetaEffectNames,
+ [2] = noop_down,
},
}
diff --git a/defaults.lua b/defaults.lua
index 52f0c20..9d21b7c 100644
--- a/defaults.lua
+++ b/defaults.lua
@@ -137,7 +137,7 @@ classNameOptions = {
defaultVars = {
dataMajorVersion = 1,
- dataMinorVersion = 1,
+ dataMinorVersion = 2,
weightsList = {
[1] = "DEATHKNIGHT",
[2] = "DRUID",
@@ -534,13 +534,13 @@ defaultVars = {
neverBreakSocketColors = false,
normalizeWeights = true,
gemQualityLimit = 9,
- showClassNames = "Others",
tooltip = {
hideHints = false,
showWeights = "Always",
showIdealWeights = "Shift",
showIdealGems = "Control",
showIdealGemStats = "Always",
+ showClassNames = "Others",
},
},
}