Fix a bug with anonymous pull.
This commit is contained in:
parent
dd548c91ab
commit
8d40f12165
1 changed files with 5 additions and 1 deletions
|
@ -180,7 +180,11 @@ def get_repository_images(namespace, repository):
|
|||
resp = make_response(json.dumps(all_images), 200)
|
||||
resp.mimetype = 'application/json'
|
||||
|
||||
mixpanel.track(get_authenticated_user().username, 'pull_repo')
|
||||
pull_username = 'anonymous'
|
||||
if get_authenticated_user():
|
||||
pull_username = get_authenticated_user().username
|
||||
|
||||
mixpanel.track(pull_username, 'pull_repo')
|
||||
|
||||
return resp
|
||||
|
||||
|
|
Reference in a new issue