Support assignment in ClassLookupDict

This commit is contained in:
Tom Christie 2015-01-23 15:32:21 +00:00
parent 5bb348605e
commit 889a07f556

View File

@ -38,6 +38,9 @@ class ClassLookupDict(object):
return self.mapping[cls] return self.mapping[cls]
raise KeyError('Class %s not found in lookup.', cls.__name__) 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): def needs_label(model_field, field_name):
""" """