fix: consistent error response on name change (#28866)

This commit is contained in:
Zachary Hancock
2021-10-04 16:32:34 -04:00
committed by GitHub
parent c162a25045
commit ae0927713d

View File

@@ -450,7 +450,7 @@ class NameChangeView(APIView):
return Response(status=status.HTTP_201_CREATED)
else:
return Response(
'The name given was identical to the current name.',
{'new_name': 'The profile name given was identical to the current name.'},
status=status.HTTP_400_BAD_REQUEST
)