MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / updateWinnerStatusByUser

Function updateWinnerStatusByUser

lottery/lottery.ts:488–498  ·  view source on GitHub ↗
(lotteryId: number, userId: string, status: PrizeStatus, claimedAt?: number)

Source from the content-addressed store, hash-verified

486 `);
487 const result = stmt.run(status, claimedAt || Date.now(), lotteryId, userId);
488 return result.changes > 0;
489}
490
491function getWinnerStatusIcon(status: string): string {
492 switch (status) {
493 case PrizeStatus.SENT:
494 return "✅";
495 case PrizeStatus.PENDING:
496 return "⏳";
497 case PrizeStatus.EXPIRED:
498 return "❌";
499 default:
500 return "❓";
501 }

Callers 1

lotteryFunction · 0.85

Calls 1

runMethod · 0.80

Tested by

no test coverage detected