Skip to content

Commit

Permalink
Fix[auth]: unexpectedly try to get token from local acc
Browse files Browse the repository at this point in the history
  • Loading branch information
khanhduytran0 committed Apr 16, 2024
1 parent 0a87c96 commit 89c9ad4
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ public String save() throws IOException {
public static MinecraftAccount parse(String content) throws JsonSyntaxException {
MinecraftAccount account = Tools.GLOBAL_GSON.fromJson(content, MinecraftAccount.class);
// Read access token from keychain
account.accessToken = getAccessTokenFromKeychain(account.xuid);
if (account.xuid != null) {
account.accessToken = getAccessTokenFromKeychain(account.xuid);
}
return account;
}

Expand Down

0 comments on commit 89c9ad4

Please sign in to comment.