Update code to use 0 instead of NULL for libraryID
This commit is contained in:
parent
368e568fe1
commit
4ea5e2d426
28 changed files with 213 additions and 313 deletions
|
@ -156,13 +156,8 @@ ZoteroAutoComplete.prototype.startSearch = function(searchString, searchParams,
|
|||
fromSQL += ")";
|
||||
}
|
||||
if (typeof searchParams.libraryID != 'undefined') {
|
||||
if (searchParams.libraryID) {
|
||||
fromSQL += " AND libraryID=?";
|
||||
sqlParams.push(searchParams.libraryID);
|
||||
}
|
||||
else {
|
||||
fromSQL += " AND libraryID IS NULL";
|
||||
}
|
||||
fromSQL += " AND libraryID=?";
|
||||
sqlParams.push(searchParams.libraryID);
|
||||
}
|
||||
|
||||
sql += fromSQL;
|
||||
|
|
|
@ -696,7 +696,7 @@ function ChromeExtensionHandler() {
|
|||
default:
|
||||
type = 'library';
|
||||
var s = new Zotero.Search();
|
||||
s.addCondition('libraryID', 'is', id ? id : null);
|
||||
s.addCondition('libraryID', 'is', id ? id : 0);
|
||||
s.addCondition('noChildren', 'true');
|
||||
var ids = s.search();
|
||||
var results = Zotero.Items.get(ids);
|
||||
|
|
|
@ -61,6 +61,7 @@ const xpcomFilesLocal = [
|
|||
'cookieSandbox',
|
||||
'data_access',
|
||||
'data/dataObjects',
|
||||
'data/dataObjectUtilities',
|
||||
'data/cachedTypes',
|
||||
'data/item',
|
||||
'data/items',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue