commit 4c2a37e51035e97f9c3ebb62eda9d3bdd25373d6
parent 78731858ab111c800f13ec52ffcc46cc526efc5d
Author: Dan Stillman <dstillman@zotero.org>
Date: Wed, 20 Aug 2008 14:52:24 +0000
Fixes saved search syncing, probably
Diffstat:
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/chrome/content/zotero/xpcom/data/dataObjects.js b/chrome/content/zotero/xpcom/data/dataObjects.js
@@ -1,4 +1,4 @@
-Zotero.DataObjects = function (object, objectPlural) {
+Zotero.DataObjects = function (object, objectPlural, id, table) {
var self = this;
if (!object) {
@@ -11,8 +11,8 @@ Zotero.DataObjects = function (object, objectPlural) {
this._ZDO_Object = object.substr(0, 1).toUpperCase() + object.substr(1);
this._ZDO_Objects = this._ZDO_objects.substr(0, 1).toUpperCase()
+ this._ZDO_objects.substr(1);
- this._ZDO_id = object + 'ID';
- this._ZDO_table = this._ZDO_objects;
+ this._ZDO_id = (id ? id : object) + 'ID';
+ this._ZDO_table = table ? table : this._ZDO_objects;
/**
diff --git a/chrome/content/zotero/xpcom/search.js b/chrome/content/zotero/xpcom/search.js
@@ -1483,7 +1483,7 @@ Zotero.Search.prototype._generateKey = function () {
Zotero.Searches = new function(){
- Zotero.DataObjects.apply(this, ['search', 'searches']);
+ Zotero.DataObjects.apply(this, ['search', 'searches', 'savedSearch', 'savedSearches']);
this.constructor.prototype = new Zotero.DataObjects();
this.get = get;