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

This commit is contained in:
Dan Stillman 2006-06-29 01:06:02 +00:00
parent 45b9234996
commit 098b7b1b9e

View File

@ -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'){