Skip to content

Commit 042c5ee

Browse files
victorneuretVladislavMedved
authored andcommitted
Fix default value syntax
1 parent e107474 commit 042c5ee

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/index.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -931,7 +931,10 @@ MapboxGeocoder.prototype = {
931931
* @param {boolean} [showSuggestions=false] display suggestion on setInput call
932932
* @returns {MapboxGeocoder} this
933933
*/
934-
setInput: function(searchInput, showSuggestions = true) {
934+
setInput: function(searchInput, showSuggestions) {
935+
if (showSuggestions === undefined) {
936+
showSuggestions = false
937+
}
935938
// Set input value to passed value and clear everything else.
936939
this._inputEl.value = searchInput;
937940
this._typeahead.selected = null;

0 commit comments

Comments
 (0)