cleanup, fix Permission Denied when Cancelling login, fix display of messages on login template

This commit is contained in:
Jens Langhammer
2019-02-25 13:02:50 +01:00
parent 07f5dce97a
commit da5568b571
8 changed files with 73 additions and 50 deletions

View File

@ -107,8 +107,8 @@ class EnableView(LoginRequiredMixin, FormView):
self.static_device = StaticDevice(user=request.user, confirmed=False)
self.static_device.save()
# Create 9 tokens and save them
# pylint: disable=unused-variable
for counter in range(0, 9):
# TODO: Send static tokens via E-Mail
for _counter in range(0, 9):
token = StaticToken(device=self.static_device, token=StaticToken.random_token())
token.save()
else: