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

Function parseIndex

music_hub/music_hub.ts:233–237  ·  view source on GitHub ↗
(text?: string)

Source from the content-addressed store, hash-verified

231function clampPage(page: number, totalPages: number): number {
232 return Math.min(Math.max(page, 1), Math.max(totalPages, 1));
233}
234
235function formatArtists(artist: string[]): string {
236 return artist.filter(Boolean).join(" / ") || "未知歌手";
237}
238
239function formatBytes(bytes?: number): string {
240 if (!bytes || bytes <= 0) return "未知大小";

Callers 1

handleCommandMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected