Not convinced the regex's would guarantee that it is a legal IPv4 or IPv6 address, but I guess that isn't exactly what we are checking for here.  No change needed!