mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-26 11:33:59 +03:00
Fixed reversed arguments in assertion
This commit is contained in:
parent
0fa9866848
commit
103fed9667
|
@ -690,7 +690,7 @@ class ModelSerializer(Serializer):
|
|||
assert field_name in ret, \
|
||||
"Noexistant field '%s' specified in `read_only_fields` " \
|
||||
"on serializer '%s'." % \
|
||||
(self.__class__.__name__, field_name)
|
||||
(field_name, self.__class__.__name__)
|
||||
ret[field_name].read_only = True
|
||||
|
||||
return ret
|
||||
|
|
Loading…
Reference in New Issue
Block a user