From 3ce3ad7fb0ea09a9a311d3300f941ae575f66a0a Mon Sep 17 00:00:00 2001 From: David Foster Date: Tue, 1 Apr 2014 14:22:41 -0700 Subject: [PATCH] Allow an empty string to be used as the placeholder title. --- select2.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/select2.js b/select2.js index 3beb6420..9d314f0e 100644 --- a/select2.js +++ b/select2.js @@ -2219,7 +2219,7 @@ the specific language governing permissions and limitations under the Apache Lic isPlaceholderOptionSelected: function() { var placeholderOption; - if (!this.getPlaceholder()) return false; // no placeholder specified so no option should be considered + if (this.getPlaceholder() === undefined) return false; // no placeholder specified so no option should be considered return ((placeholderOption = this.getPlaceholderOption()) !== undefined && placeholderOption.prop("selected")) || (this.opts.element.val() === "") || (this.opts.element.val() === undefined)