Fix cache IDs and discover route for music/book types
Some checks failed
Rebuild Issue Index / build-index (push) Has been cancelled
Close Stale Issues and PRs / Close stale issues and PRs (push) Has been cancelled
Trivy Container Vulnerability Scan / Scan latest container image (push) Has been cancelled
Check Docs Links / Verify external links in Markdown and MDX (push) Has been cancelled
CodeQL / Analyze (actions) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
Some checks failed
Rebuild Issue Index / build-index (push) Has been cancelled
Close Stale Issues and PRs / Close stale issues and PRs (push) Has been cancelled
Trivy Container Vulnerability Scan / Scan latest container image (push) Has been cancelled
Check Docs Links / Verify external links in Markdown and MDX (push) Has been cancelled
CodeQL / Analyze (actions) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
This commit is contained in:
@@ -737,7 +737,9 @@ discoverRoutes.get('/trending', async (req, res, next) => {
|
||||
}),
|
||||
} as const;
|
||||
|
||||
const { data, mapper, type } = await trendingFetchers[mediaType]();
|
||||
// Music/book don't have TMDB trending - fall back to 'all'
|
||||
const fetcherKey = (mediaType === 'music' || mediaType === 'book') ? 'all' : mediaType;
|
||||
const { data, mapper, type } = await trendingFetchers[fetcherKey]();
|
||||
|
||||
const media = await Media.getRelatedMedia(
|
||||
req.user,
|
||||
|
||||
Reference in New Issue
Block a user