Fix base schema None issue in handler too

This commit is contained in:
Joshua Boniface 2021-06-14 21:13:40 -04:00
parent 953e46055a
commit 5f11b3198b
1 changed files with 4 additions and 1 deletions

View File

@ -50,7 +50,10 @@ class ZKConnection(object):
def connection(*args, **kwargs): def connection(*args, **kwargs):
zkhandler = ZKHandler(self.config) zkhandler = ZKHandler(self.config)
zkhandler.connect() zkhandler.connect()
zkhandler.schema.load(zkhandler.read('base.schema.version'), quiet=True) schema_version = zkhandler.read('base.schema.version')
if schema_version is None:
schema_version = 0
zkhandler.schema.load(schema_version, quiet=True)
ret = function(zkhandler, *args, **kwargs) ret = function(zkhandler, *args, **kwargs)