From 751c360214123e97e521270178bbd86f1e6daacf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=B4me=20Chilliet?= <come@opensides.be> Date: Mon, 4 Jul 2016 08:01:47 +0200 Subject: [PATCH] Fixes #4974 Accept attributes with value 0 in LDIF import --- include/class_ldap.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/class_ldap.inc b/include/class_ldap.inc index 34f8d78cd..9a43ced0a 100644 --- a/include/class_ldap.inc +++ b/include/class_ldap.inc @@ -1150,7 +1150,7 @@ class LDAP if (preg_match('/^</', $value)) { throw new Exception(sprintf(_('Error line %s, references to an external file are not supported'), $lineNumber)); } - if (empty($value)) { + if ($value === '') { throw new Exception(sprintf(_('Error line %s, attribute "%s" has no value'), $lineNumber, $key)); } if ($key == 'dn') { -- GitLab