diff --git a/ldap_servers/LdapServer.class.php b/ldap_servers/LdapServer.class.php
index 9d98c2d..1fa9f37 100644
--- a/ldap_servers/LdapServer.class.php
+++ b/ldap_servers/LdapServer.class.php
@@ -1195,18 +1195,18 @@ class LdapServer {
    */
   function userUserNameToExistingLdapEntry($drupal_user_name, $ldap_context = NULL) {
 
+    if (!$ldap_context) {
+      $ldap_context = 'all';
+    }
+
     $watchdog_tokens = array('%drupal_user_name' => $drupal_user_name);
     $ldap_username = $this->userUsernameToLdapNameTransform($drupal_user_name, $watchdog_tokens);
     if (!$ldap_username) {
       return FALSE;
     }
-    if (!$ldap_context) {
-      $attributes = array();
-    }
-    else {
-      $attribute_maps = ldap_servers_attributes_needed($this->sid, $ldap_context);
-      $attributes = array_keys($attribute_maps);
-    }
+
+    $attribute_maps = ldap_servers_attributes_needed($this->sid, $ldap_context);
+    $attributes = array_keys($attribute_maps);
 
     foreach ($this->basedn as $basedn) {
       if (empty($basedn)) continue;
