Skip to content
Snippets Groups Projects
Commit e978484a authored by Iustin Pop's avatar Iustin Pop
Browse files

Remove obsolete ConfigObject.__setitem__


__setitem__ is used to emulate container objects. We don't use this, and
the method is not used in a couple of normal operations (add/remove
instance, add/remove disk).

Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
parent bd315bfa
No related branches found
No related tags found
No related merge requests found
...@@ -99,11 +99,6 @@ class ConfigObject(object): ...@@ -99,11 +99,6 @@ class ConfigObject(object):
(type(self).__name__, name)) (type(self).__name__, name))
return None return None
def __setitem__(self, key, value):
if key not in self.__slots__:
raise KeyError(key)
setattr(self, key, value)
def __setstate__(self, state): def __setstate__(self, state):
for name in state: for name in state:
if name in self.__slots__: if name in self.__slots__:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment