fixed logic for network setup in HA