Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

doofinder

Package Overview
Dependencies
Maintainers
1
Versions
198
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

doofinder - npm Package Compare versions

Comparing version 1.0.7 to 1.0.8

2

bower.json
{
"name": "doofinder",
"description": "Javascript Library for Doofinder Search API",
"version": "1.0.7",
"version": "1.0.8",
"main": "dist/doofinder.js",

@@ -6,0 +6,0 @@ "authors": [

@@ -76,3 +76,6 @@

maxQueryLength = 255;
if (query === null || !query.constructor === String) {
if (typeof query === "undefined") {
throw Error("Query must be a defined");
}
if (query === null || query.constructor !== String) {
throw Error("Query must be a String");

@@ -135,5 +138,5 @@ }

_this = this;
return this._sanitizeQuery(query, function(res) {
var filterKey, filterTerms, headers, options, paramKey, paramValue, processResponse, queryString, req;
params.query = res;
return this._sanitizeQuery(query, function(cleaned) {
var filterKey, filterTerms, headers, options, paramKey, paramValue, queryString, req;
params.query = cleaned;
headers = {};

@@ -169,19 +172,2 @@ if (_this.apiKey) {

}
processResponse = function(res) {
var data;
if (res.statusCode >= 400) {
return callback(res.statusCode, null);
} else {
data = "";
res.on('data', function(chunk) {
return data += chunk;
});
res.on('end', function() {
return callback(null, JSON.parse(data));
});
return res.on('error', function(err) {
return callback(err, null);
});
}
};
req = httpLib.request(options, _this.__processResponse(callback));

@@ -188,0 +174,0 @@ return req.end();

@@ -192,7 +192,9 @@

Controller.prototype.refresh = function() {
this.trigger("df:refresh", [this.status.params]);
this.status.currentPage = 1;
this.status.firstQueryTriggered = true;
this.status.lastPageReached = false;
return this.__search();
if (this.status.params.query) {
this.trigger("df:refresh", [this.status.params]);
this.status.currentPage = 1;
this.status.firstQueryTriggered = true;
this.status.lastPageReached = false;
return this.__search();
}
};

@@ -199,0 +201,0 @@

(function() {
module.exports = {
version: "1.0.7",
version: "1.0.8",
Client: require("./client"),

@@ -5,0 +5,0 @@ Handlebars: require("handlebars"),

{
"name": "doofinder",
"version": "1.0.7",
"version": "1.0.8",
"description": "Javascript Library for Doofinder Search API",

@@ -5,0 +5,0 @@ "main": "lib/doofinder.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc