events: rename context.token to context.secret

This commit is contained in:
Jens Langhammer
2021-02-09 20:10:43 +01:00
parent 71c9108f89
commit a7d0a50859
3 changed files with 12 additions and 6 deletions

View File

@ -49,5 +49,7 @@ class TokenViewSet(ModelViewSet):
if not tokens.exists():
raise Http404
token = tokens.first()
Event.new(EventAction.SECRET_VIEW, token=token).from_http(request)
Event.new( # noqa # nosec
EventAction.SECRET_VIEW, secret=token
).from_http(request)
return Response(TokenViewSerializer({"key": token.key}).data)