# Catalog Routing: ctmdb.* → Native TMDB

## Problem
`ctmdb.*` catalog IDs (e.g. `ctmdb.newReleases`, `ctmdb.popular`) come from the TMDB Collections Stremio addon. The catalog worker's regex only matched `movie|series|tv`, so `type=collections` returned 404.

## Fix (Android side — no worker deploy needed)
1. Add `ctmdb.` prefix to `isNativeCatalogId()` in `AddonRepository.kt`:
   ```kotlin
   catalogId.startsWith("ctmdb.") ||
   ```
2. Add `ctmdb.` to Tier 1 check for direct TMDB resolution
3. In `TmdbCatalogRepository.normalizeCatalogId()`, strip `ctmdb.` → `tmdb.`:
   ```kotlin
   else -> catalogId.replaceFirst("ctmdb.", "tmdb.")
   ```
4. Worker safety net: extend CatalogType to `'movie' | 'series' | 'tv' | 'collections'`

## Result
`ctmdb.*` catalogs now use local TMDB API directly → no worker roundtrip, no 404s.
