mirror of
https://github.com/xcat2/confluent.git
synced 2024-11-26 03:19:48 +00:00
Fix restoration of old confluent db
Old confluent DB may have None in role. This is no longer allowed. Restore such entries by coercing them to 'Administrator' which is how old confluent treated such users.
This commit is contained in:
parent
03fcd3f568
commit
feed125c86
@ -1625,6 +1625,8 @@ class ConfigManager(object):
|
||||
name = confluent.util.stringify(name)
|
||||
if name in self._cfgstore['users']:
|
||||
raise Exception("Duplicate username requested")
|
||||
if role is None:
|
||||
role = 'Administrator'
|
||||
for candrole in _validroles:
|
||||
if candrole.lower().startswith(role.lower()):
|
||||
role = candrole
|
||||
|
Loading…
Reference in New Issue
Block a user