Mercurial > wow > recipeprofit
comparison core.lua @ 59:962cafb5915d v2.08
Fixed CleanupDatabase range.
| author | Aaron@MATT-DAMON |
|---|---|
| date | Sun, 21 Aug 2011 12:33:57 -0500 |
| parents | 993b57631e81 |
| children |
comparison
equal
deleted
inserted
replaced
| 58:63dcee910f5e | 59:962cafb5915d |
|---|---|
| 150 db.storage = {} | 150 db.storage = {} |
| 151 | 151 |
| 152 GatherMate:GetModule("Config"):RegisterModule("RecipeProfit", options) | 152 GatherMate:GetModule("Config"):RegisterModule("RecipeProfit", options) |
| 153 GatherMate:RegisterDBType("RecipeProfit", db.storage) | 153 GatherMate:RegisterDBType("RecipeProfit", db.storage) |
| 154 GatherMate.db.profile.show["RecipeProfit"] = GatherMate.db.profile.show["RecipeProfit"] or "always" | 154 GatherMate.db.profile.show["RecipeProfit"] = GatherMate.db.profile.show["RecipeProfit"] or "always" |
| 155 | 155 GatherMate.db.profile.cleanupRange["RecipeProfit"] = 0.0; |
| 156 | |
| 156 set_node_constants() | 157 set_node_constants() |
| 157 inject_options() | 158 inject_options() |
| 158 | 159 |
| 159 GatherMate:GetModule("Config"):UpdateConfig() | 160 GatherMate:GetModule("Config"):UpdateConfig() |
| 160 GatherMate:GetModule("Config"):SendMessage("GatherMate2ConfigChanged") | 161 GatherMate:GetModule("Config"):SendMessage("GatherMate2ConfigChanged") |
| 172 | 173 |
| 173 --[[hook OnProfileChanged to fix cleanup database ]] | 174 --[[hook OnProfileChanged to fix cleanup database ]] |
| 174 local oldFunction2 = GatherMate.OnProfileChanged | 175 local oldFunction2 = GatherMate.OnProfileChanged |
| 175 | 176 |
| 176 GatherMate.OnProfileChanged = function(lself, ...) | 177 GatherMate.OnProfileChanged = function(lself, ...) |
| 177 lself.db.profile.cleanupRange["RecipeProfit"] = lself.db.profile.cleanupRange["RecipeProfit"] or 15 | 178 lself.db.profile.cleanupRange["RecipeProfit"] = lself.db.profile.cleanupRange["RecipeProfit"] or 0.0; |
| 178 lself.db.profile.show["RecipeProfit"] = lself.db.profile.show["RecipeProfit"] == "never" and "never" or "always"; | 179 lself.db.profile.show["RecipeProfit"] = lself.db.profile.show["RecipeProfit"] == "never" and "never" or "always"; |
| 179 oldFunction2(lself, ...) | 180 oldFunction2(lself, ...) |
| 180 end | 181 end |
| 181 | 182 |
| 182 end | 183 end |
