From 7703bf482ad2948c0b65f3fa75bc0e839036328d Mon Sep 17 00:00:00 2001 From: Yicheng Li Date: Tue, 2 Jul 2019 14:08:16 -0400 Subject: [PATCH] Bugfix for undefined array index error when getting ldap groups for a user. --- src/Objects/Ldap/Entry.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Objects/Ldap/Entry.php b/src/Objects/Ldap/Entry.php index d21da38..0a689b7 100644 --- a/src/Objects/Ldap/Entry.php +++ b/src/Objects/Ldap/Entry.php @@ -48,7 +48,7 @@ private function applyAttributes($attributes) if (array_key_exists('count', $attributes[$key]) && $attributes[$key]['count'] > 1) { $data = []; - for ($i = 0; $i <= $attributes[$key]['count']; $i++) { + for ($i = 0; $i < $attributes[$key]['count']; $i++) { $data[] = $attributes[$key][$i]; }