oops, fix copy and paste error (check ipv4 != "")

This commit is contained in:
forest 2021-12-19 12:11:56 -06:00
parent cd26fcec5d
commit 4d2c74c1d8

View File

@ -31,7 +31,7 @@ def double_check_capsul_address(id, existing_ipv4, get_ssh_host_keys):
try:
result = current_app.config["HUB_MODEL"].get(id, get_ssh_host_keys)
if result != None and result != "" and (existing_ipv4 == None or existing_ipv4 == ""):
if result != None and result.ipv4 != "" and (existing_ipv4 == None or existing_ipv4 == ""):
get_model().update_vm_ip(email=session["account"], id=id, ipv4=result.ipv4)
if result != None and result.ssh_host_keys != None and get_ssh_host_keys: