mirror of
https://github.com/ppy/osu.git
synced 2024-11-14 15:17:27 +08:00
Remove redundant api
field from HubClientConnector
This commit is contained in:
parent
1c612e2e0c
commit
2391035e49
@ -27,7 +27,6 @@ namespace osu.Game.Online
|
|||||||
private readonly string endpoint;
|
private readonly string endpoint;
|
||||||
private readonly string versionHash;
|
private readonly string versionHash;
|
||||||
private readonly bool preferMessagePack;
|
private readonly bool preferMessagePack;
|
||||||
private readonly IAPIProvider api;
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The current connection opened by this connector.
|
/// The current connection opened by this connector.
|
||||||
@ -47,7 +46,6 @@ namespace osu.Game.Online
|
|||||||
{
|
{
|
||||||
ClientName = clientName;
|
ClientName = clientName;
|
||||||
this.endpoint = endpoint;
|
this.endpoint = endpoint;
|
||||||
this.api = api;
|
|
||||||
this.versionHash = versionHash;
|
this.versionHash = versionHash;
|
||||||
this.preferMessagePack = preferMessagePack;
|
this.preferMessagePack = preferMessagePack;
|
||||||
|
|
||||||
@ -70,7 +68,7 @@ namespace osu.Game.Online
|
|||||||
options.Proxy.Credentials = CredentialCache.DefaultCredentials;
|
options.Proxy.Credentials = CredentialCache.DefaultCredentials;
|
||||||
}
|
}
|
||||||
|
|
||||||
options.Headers.Add("Authorization", $"Bearer {api.AccessToken}");
|
options.Headers.Add("Authorization", $"Bearer {API.AccessToken}");
|
||||||
options.Headers.Add("OsuVersionHash", versionHash);
|
options.Headers.Add("OsuVersionHash", versionHash);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user