docs: add JSDoc to service public methods
One-line JSDoc on 82 methods across 11 service files for quick scanning without reading full implementations. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -213,12 +213,20 @@ async function clearCaches() {
|
||||
}
|
||||
|
||||
export const lootdropService = {
|
||||
/** Delete expired lootdrops from the database; optionally includes already-claimed ones. */
|
||||
cleanupExpiredLootdrops,
|
||||
/** Record a message in a channel and return whether a lootdrop should spawn based on activity and RNG. */
|
||||
trackActivity,
|
||||
/** Calculate a random lootdrop reward amount and currency, with optional overrides. */
|
||||
calculateReward,
|
||||
/** Save a spawned lootdrop to the database with a 10-minute expiration. */
|
||||
persistLootdrop,
|
||||
/** Remove a lootdrop by message ID and return its channel ID for Discord cleanup. */
|
||||
removeLootdrop,
|
||||
/** Atomically claim a lootdrop for a user; credits reward to their balance. */
|
||||
tryClaim,
|
||||
/** Get current lootdrop system state including the most active channel and spawn config. */
|
||||
getLootdropState,
|
||||
/** Clear all in-memory activity tracking and cooldown caches. */
|
||||
clearCaches,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user