Eliminate all of the exceptions when running the tests.
This commit is contained in:
parent
e1b704bdac
commit
6f39e158d6
10 changed files with 50 additions and 10 deletions
|
@ -33,7 +33,8 @@ class EntitySearch(ApiResource):
|
|||
|
||||
except model.InvalidOrganizationException:
|
||||
# namespace name was a user
|
||||
if get_authenticated_user().username == namespace_name:
|
||||
user = get_authenticated_user()
|
||||
if user and user.username == namespace_name:
|
||||
robot_namespace = namespace_name
|
||||
|
||||
users = model.get_matching_users(prefix, robot_namespace, organization)
|
||||
|
|
Reference in a new issue