public static HttpWebRequest Cookie(this HttpWebRequest request, string keyValue, string domain) { if (request is null) { throw new ArgumentNullException(nameof(request)); } if (keyValue is null) { throw new ArgumentNullException(nameof(keyValue)); } var parts = keyValue.SplitX('='); return(request.Cookie(parts[0], parts[1], domain)); }