From 42b4b173f33c556aa03f880aa06ec495f3a85665 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Mon, 21 Jun 2021 01:14:44 -0400 Subject: [PATCH] Store `lastCompatibleVersion` during schema initialization Otherwise switching back to release from beta doesn't show the last-used version if the beta hasn't gone through at least one compatibility-breaking schema update. --- chrome/content/zotero/xpcom/schema.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chrome/content/zotero/xpcom/schema.js b/chrome/content/zotero/xpcom/schema.js index c98643a03b..d0038a10cc 100644 --- a/chrome/content/zotero/xpcom/schema.js +++ b/chrome/content/zotero/xpcom/schema.js @@ -2214,7 +2214,6 @@ Zotero.Schema = new function(){ yield _getSchemaSQLVersion('triggers').then(function (version) { return _updateDBVersion('triggers', version); }); - yield _updateDBVersion('compatibility', _maxCompatibility); var sql = "INSERT INTO libraries (libraryID, type, editable, filesEditable) " + "VALUES " @@ -2222,6 +2221,7 @@ Zotero.Schema = new function(){ yield Zotero.DB.queryAsync(sql, userLibraryID); yield _updateLastClientVersion(); + yield _updateCompatibility(_maxCompatibility); self.dbInitialized = true; })