X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=osmclient%2Fsol005%2Fuser.py;h=15848783092409609838f5c1dff624eb2a12837b;hb=e0fb4995c67792f01648cbc7e331879fc661a572;hp=660c944821beaab7feb9de3cd0dafc479a3b00f0;hpb=c7393b88143880b33e7a46916159ed49049b58a2;p=osm%2Fosmclient.git diff --git a/osmclient/sol005/user.py b/osmclient/sol005/user.py index 660c944..1584878 100644 --- a/osmclient/sol005/user.py +++ b/osmclient/sol005/user.py @@ -214,9 +214,11 @@ class User(object): self._client.get_token() # keystone with external LDAP contains large ids, not uuid format # utils.validate_uuid4(name) cannot be used - for user in self.list(): + user_list = self.list() + for user in user_list: if name == user['_id']: return user + for user in user_list: if name == user['username']: return user raise NotFound("User {} not found".format(name))