/// <summary> /// Normalizes a host value. /// </summary> public NormalizedHttpHost(string host) { if (host == null) throw new ArgumentNullException(nameof(host)); if (host == "") throw new ArgumentException("Host is required.", nameof(host)); _host = new NormalizedHost(host); }
/// <summary> /// Normalizes a host value. /// </summary> public NormalizedHttpHost(string?host) { if (host == null) { throw new ArgumentNullException(nameof(host)); } if (host.Length == 0) { throw new ArgumentException("Host is required.", nameof(host)); } _host = new NormalizedHost(host); }