mirror of https://gitlab.crans.org/bde/nk20
BaseException.message is removed in Python 3
This commit is contained in:
parent
93bc6bb245
commit
1ca5133026
|
@ -82,7 +82,7 @@ class AliasViewSet(ReadProtectedModelViewSet):
|
|||
try:
|
||||
self.perform_destroy(instance)
|
||||
except ValidationError as e:
|
||||
return Response({e.code: e.message}, status.HTTP_400_BAD_REQUEST)
|
||||
return Response({e.code: str(e)}, status.HTTP_400_BAD_REQUEST)
|
||||
return Response(status=status.HTTP_204_NO_CONTENT)
|
||||
|
||||
def get_queryset(self):
|
||||
|
|
Loading…
Reference in New Issue