Use empty string for node limit

This commit is contained in:
Joshua Boniface 2019-10-22 12:32:14 -04:00
parent f0e0a38a20
commit 190623bdd9
1 changed files with 3 additions and 3 deletions

View File

@ -144,10 +144,10 @@ def findTargetNode(zk_conn, config, dom_uuid):
try: try:
node_limit = zkhandler.readdata(zk_conn, '/domains/{}/node_limit'.format(dom_uuid)).split(',') node_limit = zkhandler.readdata(zk_conn, '/domains/{}/node_limit'.format(dom_uuid)).split(',')
if not any(node_limit): if not any(node_limit):
node_limit = None node_limit = ''
except: except:
node_limit = None node_limit = ''
zkhandler.writedata(zk_conn, { '/domains/{}/node_limit'.format(dom_uuid): 'None' }) zkhandler.writedata(zk_conn, { '/domains/{}/node_limit'.format(dom_uuid): '' })
# Determine VM search field or use default; set config value if read fails # Determine VM search field or use default; set config value if read fails
try: try: