From da21c9c47bccb651ab64eb9211c001fb53d90c1b Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Fri, 22 Sep 2017 16:56:23 -0400 Subject: [PATCH] Remove old archive.org relations These aren't allowed by the API and were breaking syncing (and haven't been exposed anywhere for years anyway). --- chrome/content/zotero/xpcom/schema.js | 4 ++++ resource/schema/userdata.sql | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/chrome/content/zotero/xpcom/schema.js b/chrome/content/zotero/xpcom/schema.js index 7fda50779..a833c26fc 100644 --- a/chrome/content/zotero/xpcom/schema.js +++ b/chrome/content/zotero/xpcom/schema.js @@ -2479,6 +2479,10 @@ Zotero.Schema = new function(){ yield Zotero.DB.queryAsync("DELETE FROM relationPredicates " + where); } + else if (i == 98) { + yield Zotero.DB.queryAsync("DELETE FROM itemRelations WHERE predicateID=(SELECT predicateID FROM relationPredicates WHERE predicate='owl:sameAs') AND object LIKE ?", 'http://www.archive.org/%'); + } + // If breaking compatibility or doing anything dangerous, clear minorUpdateFrom } diff --git a/resource/schema/userdata.sql b/resource/schema/userdata.sql index badb8fda8..cd60cf158 100644 --- a/resource/schema/userdata.sql +++ b/resource/schema/userdata.sql @@ -1,4 +1,4 @@ --- 97 +-- 98 -- Copyright (c) 2009 Center for History and New Media -- George Mason University, Fairfax, Virginia, USA