2
0
mirror of https://github.com/xcat2/confluent.git synced 2025-01-09 04:56:12 +00:00

Removing unnecessary case if groups ever has a key of 'value'

This commit is contained in:
Allen Lin37 2017-04-20 15:41:11 -04:00
parent 86e502a47a
commit b64858e0b3

View File

@ -896,11 +896,6 @@ class ConfigManager(object):
if node not in self._cfgstore['nodes']:
self._cfgstore['nodes'][node] = {'groups': [group]}
_mark_dirtykey('nodes', node, self.tenant)
elif 'value' in self._cfgstore['nodes'][node]['groups']:
tmplist=self._cfgstore['nodes'][node]['groups']['value'].split(",")
tmplist.insert(0, unicode(group))
self._cfgstore['nodes'][node]['groups']['value']=",".join(tmplist)
_mark_dirtykey('nodes', node, self.tenant)
elif group not in self._cfgstore['nodes'][node]['groups']:
self._cfgstore['nodes'][node]['groups'].insert(0, group)
_mark_dirtykey('nodes', node, self.tenant)