From 2cb435680ba223bde5eb9a3bdf877b36b16344cb Mon Sep 17 00:00:00 2001 From: Igor Vaynberg Date: Mon, 17 Sep 2012 19:34:50 -0700 Subject: [PATCH] fixes #366 --- select2.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/select2.js b/select2.js index e0e946f1..3bc3d356 100644 --- a/select2.js +++ b/select2.js @@ -1216,8 +1216,12 @@ } } - if (search.val().length < opts.minimumInputLength && checkFormatter(opts.formatInputTooShort, "formatInputTooShort")) { - render("
  • " + opts.formatInputTooShort(search.val(), opts.minimumInputLength) + "
  • "); + if (search.val().length < opts.minimumInputLength) { + if (checkFormatter(opts.formatInputTooShort, "formatInputTooShort")) { + render("
  • " + opts.formatInputTooShort(search.val(), opts.minimumInputLength) + "
  • "); + } else { + render(""); + } return; } else {