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

Function getWarehousePrizes

lottery/lottery.ts:244–253  ·  view source on GitHub ↗
(warehouseName: string)

Source from the content-addressed store, hash-verified

242 ORDER BY order_index
243 `);
244 return stmt.all(warehouseName);
245}
246
247function getNextAvailablePrize(warehouseName: string): any | null {
248 if (!db) return null;
249
250 const stmt = db.prepare(`
251 SELECT * FROM prize_warehouse
252 WHERE warehouse_name = ? AND stock_count > 0
253 ORDER BY order_index
254 LIMIT 1
255 `);
256 return stmt.get(warehouseName) || null;

Callers 1

lotteryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected