Commit 59bbda4e by Dányi Bence

webui: fix invalid public key message

parent ac70cfc6
...@@ -456,7 +456,7 @@ def key_add(request): ...@@ -456,7 +456,7 @@ def key_add(request):
key.full_clean() key.full_clean()
key.save() key.save()
except ValidationError as e: except ValidationError as e:
messages.error(request, unicode(e)) messages.error(request, ''.join(e.messages))
except e: except e:
messages.error(request, _('Failed to add public key')) messages.error(request, _('Failed to add public key'))
return redirect('/') return redirect('/')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment