This fix will guess the address family of the @host, and listen on an IPv4 or IPv6 socket based on the result.
Much simpler 🐼
I also added some tests.
Fix to support IPv6 addresses
Return the correct address family