From 7e46dafe5c9812d0177c4bbf3000712bf81e3e45 Mon Sep 17 00:00:00 2001 From: Alexandre Stanislawski Date: Wed, 3 Jun 2015 17:27:47 +0200 Subject: [PATCH] Fix #92 parameters that can be set in the dashboard shouldn't have defaults --- src/SearchParameters/index.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/SearchParameters/index.js b/src/SearchParameters/index.js index 6e6a0a1e33..60e710cc48 100644 --- a/src/SearchParameters/index.js +++ b/src/SearchParameters/index.js @@ -36,6 +36,7 @@ var SearchParameters = function( newParameters ) { * @member {string} */ this.query = params.query || ""; + //Facets /** * All the facets that will be requested to the server @@ -58,16 +59,16 @@ var SearchParameters = function( newParameters ) { * @member {Object.} */ this.numericRefinements = params.numericRefinements || {}; + //Misc. parameters /** @member {number} */ - this.hitsPerPage = params.hitsPerPage || 20; + this.hitsPerPage = params.hitsPerPage; /** * @member {number} **/ - this.maxValuesPerFacet = params.maxValuesPerFacet || 10; + this.maxValuesPerFacet = params.maxValuesPerFacet; /** @member {number} */ this.page = params.page || 0; - /** * Possible values : prefixAll, prefixLast, prefixNone * @see https://www.algolia.com/doc#queryType