Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/apps/wallet-admin/src/lib/services/wallet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ export async function getPayments(limit: number, offset: number, filters: Record
}

if (filters.winnerIds && filters.winnerIds.length > 0) {
payload.winnerIds = filters.winnerIds
payload.winnerIds = filters.winnerIds.map(id => id.toString())
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[⚠️ correctness]
Converting winnerIds to strings using map(id => id.toString()) is a good approach to ensure consistency in data types. However, ensure that filters.winnerIds is always an array of numbers or strings to avoid unexpected behavior. Consider adding validation earlier in the data flow if this assumption might not hold.

}

const body = JSON.stringify(payload)
Expand Down