www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 098b7b1b9ebf24e56aa1faffdde25e81e9f1efd4
parent 45b9234996af3fabe865664268abc340a58d2813
Author: Dan Stillman <dstillman@zotero.org>
Date:   Thu, 29 Jun 2006 01:06:02 +0000

Allow single bound parameters not in arrays in DB.query() calls


Diffstat:
Mchrome/chromeFiles/content/scholar/xpcom/db.js | 5+++++
1 file changed, 5 insertions(+), 0 deletions(-)

diff --git a/chrome/chromeFiles/content/scholar/xpcom/db.js b/chrome/chromeFiles/content/scholar/xpcom/db.js @@ -169,6 +169,11 @@ Scholar.DB = new function(){ } if (statement && params){ + // If single parameter, wrap in an array + if (!params.length){ + params = [params]; + } + for (var i=0; i<params.length; i++){ // Integer if (params[i]!==null && typeof params[i]['int'] != 'undefined'){