mirror of
https://github.com/osukey/osukey.git
synced 2025-07-02 00:40:09 +09:00
Fix refresh tokens not working correctly
Turns out there's plenty of slashes in refresh tokens.
This commit is contained in:
@ -41,13 +41,13 @@ namespace osu.Game.Online.API
|
|||||||
[JsonProperty(@"refresh_token")]
|
[JsonProperty(@"refresh_token")]
|
||||||
public string RefreshToken;
|
public string RefreshToken;
|
||||||
|
|
||||||
public override string ToString() => $@"{AccessToken}/{AccessTokenExpiry.ToString(NumberFormatInfo.InvariantInfo)}/{RefreshToken}";
|
public override string ToString() => $@"{AccessToken}|{AccessTokenExpiry.ToString(NumberFormatInfo.InvariantInfo)}|{RefreshToken}";
|
||||||
|
|
||||||
public static OAuthToken Parse(string value)
|
public static OAuthToken Parse(string value)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
string[] parts = value.Split('/');
|
string[] parts = value.Split('|');
|
||||||
return new OAuthToken
|
return new OAuthToken
|
||||||
{
|
{
|
||||||
AccessToken = parts[0],
|
AccessToken = parts[0],
|
||||||
|
Reference in New Issue
Block a user