Fix if ip is empty