We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9859e9d commit 467984cCopy full SHA for 467984c
SpotifyAPI.Web/SpotifyWebClient.cs
@@ -166,12 +166,9 @@ private static WebHeaderCollection ConvertHeaders(HttpResponseHeaders headers)
166
167
private void AddHeaders(Dictionary<string,string> headers)
168
{
169
+ _client.DefaultRequestHeaders.Clear();
170
foreach (KeyValuePair<string, string> headerPair in headers)
171
- if (_client.DefaultRequestHeaders.Contains(headerPair.Key))
172
- {
173
- _client.DefaultRequestHeaders.Remove(headerPair.Key);
174
- }
175
_client.DefaultRequestHeaders.TryAddWithoutValidation(headerPair.Key, headerPair.Value);
176
}
177
0 commit comments