mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-25 19:14:01 +03:00
Support assignment in ClassLookupDict
This commit is contained in:
parent
5bb348605e
commit
889a07f556
|
@ -38,6 +38,9 @@ class ClassLookupDict(object):
|
|||
return self.mapping[cls]
|
||||
raise KeyError('Class %s not found in lookup.', cls.__name__)
|
||||
|
||||
def __setitem__(self, key, value):
|
||||
self.mapping[key] = value
|
||||
|
||||
|
||||
def needs_label(model_field, field_name):
|
||||
"""
|
||||
|
|
Loading…
Reference in New Issue
Block a user