fix: remove fediverse prefix to prevent migration error + load routes during podcast import

refactor migration queries to use forge functions
This commit is contained in:
Yassine Doghri 2023-08-26 13:03:01 +00:00
commit 7ff1dbe903
63 changed files with 387 additions and 355 deletions

View file

@ -158,12 +158,12 @@ class PlatformModel extends Model
$podcastsPlatformsTable = $this->db->prefixTable('podcasts_platforms');
$platformsTable = $this->db->prefixTable('platforms');
$deleteJoinQuery = <<<CODE_SAMPLE
$deleteJoinQuery = <<<SQL
DELETE {$podcastsPlatformsTable}
FROM {$podcastsPlatformsTable}
INNER JOIN {$platformsTable} ON {$platformsTable}.slug = {$podcastsPlatformsTable}.platform_slug
WHERE `podcast_id` = ? AND `type` = ?
CODE_SAMPLE;
SQL;
$this->db->query($deleteJoinQuery, [$podcastId, $platformType]);