summaryrefslogtreecommitdiffstats
path: root/lib/api/kolab_api_service_user.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/api/kolab_api_service_user.php')
-rw-r--r--lib/api/kolab_api_service_user.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/api/kolab_api_service_user.php b/lib/api/kolab_api_service_user.php
index 855518f..111456e 100644
--- a/lib/api/kolab_api_service_user.php
+++ b/lib/api/kolab_api_service_user.php
@@ -145,6 +145,7 @@ class kolab_api_service_user extends kolab_api_service
}
$auth = Auth::get_instance();
+ $conf = Conf::get_instance();
$user = $getdata['user'];
$result = $auth->user_info($user);
@@ -170,6 +171,16 @@ class kolab_api_service_user extends kolab_api_service
}
}
+ // Insert the persistent, unique attribute
+ $unique_attr = $conf->get('unique_attr');
+ if (!$unique_attr) {
+ $unique_attr = 'nsuniqueid';
+ }
+
+ if (!array_key_exists($unique_attr, $attrs)) {
+ $attrs[] = 'nsuniqueid';
+ }
+
if (!empty($attrs)) {
$attrs = $auth->user_attributes($result['entrydn'], $attrs);
if (!empty($attrs)) {