refactor: split tmdb into movie_id and tv_id

Step 2 in cleaner meta fetching code.
This commit is contained in:
Roardom
2025-03-13 21:27:46 +00:00
parent 09f8404ada
commit 32cf8da4db
61 changed files with 1062 additions and 708 deletions
+1 -1
View File
@@ -60,6 +60,6 @@ class Network extends Model
*/
public function tvTorrents(): \Illuminate\Database\Eloquent\Relations\BelongsToMany
{
return $this->belongsToMany(Torrent::class, 'network_tv', 'tv_id', 'network_id', 'id', 'tmdb')->whereRelation('category', 'tv_meta', '=', true);
return $this->belongsToMany(Torrent::class, 'network_tv', 'tv_id', 'network_id', 'id', 'tv_id')->whereRelation('category', 'tv_meta', '=', true);
}
}