[third] Patch bootstrap-typeahead to hide when the source fn returns false.

On the next line, it checks and returns immediately if the source returns
false, but it should first hide the existing box or else it's just left
there until the next typeahead refresh.

This fixes the issue with the typeahead not closing properly when a space
is typed that was introduced in 7aa3f762.

(imported from commit cbe77e2152d889fe53d874e97f41cfc725166929)
This commit is contained in:
Kevin Mehall 2013-07-16 11:31:57 -04:00
parent 4e043feeb1
commit 0975cfadf1
1 changed files with 1 additions and 0 deletions

View File

@ -1882,6 +1882,7 @@
items = $.isFunction(this.source) ? this.source(this.query, $.proxy(this.process, this)) : this.source items = $.isFunction(this.source) ? this.source(this.query, $.proxy(this.process, this)) : this.source
if (!items && this.shown) this.hide();
return items ? this.process(items) : this return items ? this.process(items) : this
} }