fix recognition of query format for empty queries in dictionary format

queries like {text: ""} did not get recognized correctly before and
get converted to {text: {text: ""}}
This commit is contained in:
Alexander Sulfrian 2011-11-21 11:42:23 +01:00
parent 09ee46da22
commit 5d8c8bbcdc

View File

@ -172,7 +172,7 @@ p._pulseQueryQueue = function() {
p.query = function(config, values, callback) {
//can take in strings or config objects
config = (config.text || config.name) ? config : { text: config };
config = (typeof(config) == 'string') ? { text: config } : config;
if(values) {
if(typeof values === 'function') {