changeset 136:fa7f91077c54

Flush the DB when encountering a new client build.
author James D. Callahan III <jcallahan@curse.com>
date Wed, 26 Sep 2012 13:23:56 -0500
parents 3b9d44976319
children 5f43b650e341
files Main.lua
diffstat 1 files changed, 1 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/Main.lua	Mon Sep 24 12:55:11 2012 -0500
+++ b/Main.lua	Wed Sep 26 13:23:56 2012 -0500
@@ -559,9 +559,7 @@
     local raw_db = _G["WoWDBProfilerData"]
     local build_num = tonumber(private.build_num)
 
-    -- TODO: Merge this with the DB version check when MoP goes live.
-    --    if raw_db.build_num and raw_db.build_num < build_num then
-    if raw_db.version and raw_db.version < DB_VERSION then
+    if (raw_db.version and raw_db.version < DB_VERSION) or (raw_db.build_num and raw_db.build_num < build_num) then
         for entry in pairs(DATABASE_DEFAULTS.global) do
             global_db[entry] = {}
         end