refactor: drop Number() coercion on snowflake ids
This commit is contained in:
+6
-6
@@ -80,18 +80,18 @@ export async function getOrderById(orderId: string): Promise<Order | undefined>
|
||||
}
|
||||
|
||||
interface CreatePaidOrderInput {
|
||||
playerId: string | number
|
||||
serviceId: string | number
|
||||
shopId?: string | number
|
||||
playerId: string
|
||||
serviceId: string
|
||||
shopId?: string
|
||||
quantity: number
|
||||
note?: string
|
||||
}
|
||||
|
||||
function createOrderJson(input: CreatePaidOrderInput) {
|
||||
return {
|
||||
playerId: Number(input.playerId),
|
||||
serviceId: Number(input.serviceId),
|
||||
...(input.shopId ? { shopId: Number(input.shopId) } : {}),
|
||||
playerId: input.playerId,
|
||||
serviceId: input.serviceId,
|
||||
...(input.shopId ? { shopId: input.shopId } : {}),
|
||||
quantity: input.quantity,
|
||||
...(input.note ? { note: input.note } : {}),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user