Skip to content

Commit

Permalink
fix: Fix naming for new fields
Browse files Browse the repository at this point in the history
  • Loading branch information
cyperdark committed Dec 7, 2024
1 parent dcc398f commit 4dbd01f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/tosu/src/api/types/v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export type ApiAnswerPrecise = TosuPreciseAnswer | { error?: string };

export interface TosuAPi {
client: string;
serverEndpoint: string;
server: string;
state: NumberName;
session: Session;
settings: Settings;
Expand Down Expand Up @@ -266,7 +266,7 @@ export interface Leaderboard {
isFailed: boolean;
position: number;
team: number;
userId: number;
id: number;
name: string;
score: number;
accuracy: number;
Expand Down
4 changes: 2 additions & 2 deletions packages/tosu/src/api/utils/buildResultV2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ const convertMemoryPlayerToResult = (
position: memoryPlayer.position,
team: memoryPlayer.team,

userId: memoryPlayer.userId,
id: memoryPlayer.userId,
name: memoryPlayer.name,

score: memoryPlayer.score,
Expand Down Expand Up @@ -132,7 +132,7 @@ export const buildResult = (instanceManager: InstanceManager): ApiAnswer => {

return {
client: ClientType[osuInstance.client],
serverEndpoint: osuInstance.customServerEndpoint ?? 'ppy.sh',
server: osuInstance.customServerEndpoint ?? 'ppy.sh',
state: {
number: global.status,
name: GameState[global.status] || ''
Expand Down

0 comments on commit 4dbd01f

Please sign in to comment.