plugins/data: properly clear history data when loading new file

This commit is contained in:
cracyc 2021-04-03 20:13:56 -05:00
parent 82222e9b73
commit 9c14a66139

View file

@ -80,6 +80,8 @@ local function init()
if dbver then
db.exec("DELETE FROM \"" .. file .. "\"")
db.check("deleting history")
db.exec("DELETE FROM \"" .. file .. "_idx\"")
db.check("deleting index")
stmt = db.prepare("UPDATE version SET version = ? WHERE datfile = ?")
db.check("updating history version")
else