mirror of
https://github.com/maxdorninger/MediaManager.git
synced 2026-04-20 15:55:42 +02:00
feat: enhance torrent management with new table component and improved navigation
This commit is contained in:
@@ -33,3 +33,13 @@ export function getFullyQualifiedShowName(show: { name: string; year: number }):
|
||||
}
|
||||
return name;
|
||||
}
|
||||
|
||||
export function convertTorrentSeasonRangeToIntegerRange(torrent: any): string {
|
||||
if (torrent.seasons.length === 1) return torrent.seasons[0]?.toString();
|
||||
if (torrent.seasons.length >= 2) return torrent.seasons[0]?.toString() + "-" + torrent.seasons.at(-1).toString();
|
||||
else {
|
||||
console.log("Error parsing season range: " + torrent.seasons);
|
||||
return "Error parsing season range: " + torrent.seasons;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user