Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

query dict immuteable

class Login(generics.CreateAPIView):
    serializer_class = MySerializerClass
    def create(self, request, *args, **kwargs):
        request.data._mutable = True
        request.data['username'] = "example@mail.com"
        request.data._mutable = False
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #query #dict #immuteable
ADD COMMENT
Topic
Name
7+6 =