From 21bab288b4fd9f20ee216f03386067ab643535d4 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 31 May 2011 20:36:06 +0000 Subject: [PATCH] Avoid errors when constant not defined --- htdocs/lib/ajax.lib.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/htdocs/lib/ajax.lib.php b/htdocs/lib/ajax.lib.php index 2c142498df7..7c88ae4ea94 100644 --- a/htdocs/lib/ajax.lib.php +++ b/htdocs/lib/ajax.lib.php @@ -37,6 +37,8 @@ */ function ajax_autocompleter($selected='',$htmlname,$url,$option='',$minLength=2,$autoselect=0) { + if (empty($minLength)) $minLength=1; + $script = ''; $script.= '