Fix upstream issues caused by EM clearing on media processing.
This commit is contained in:
parent
793f54413f
commit
fd67b04e71
|
@ -191,10 +191,12 @@ class StationRepository extends Repository
|
|||
// Scan directory for any existing files.
|
||||
set_time_limit(600);
|
||||
$this->media_sync->importMusic($station);
|
||||
$this->em->refresh($station);
|
||||
|
||||
$station = $this->em->find(Entity\Station::class, $station->getId());
|
||||
|
||||
$this->media_sync->importPlaylists($station);
|
||||
$this->em->refresh($station);
|
||||
|
||||
$station = $this->em->find(Entity\Station::class, $station->getId());
|
||||
|
||||
// Load adapters.
|
||||
$frontend_adapter = $this->adapters->getFrontendAdapter($station);
|
||||
|
|
|
@ -211,6 +211,8 @@ class StationCloneForm extends StationForm
|
|||
// Run normal post-creation steps.
|
||||
$this->media_sync->importMusic($new_record);
|
||||
|
||||
$new_record = $this->em->find(Entity\Station::class, $new_record_id);
|
||||
|
||||
$this->configuration->assignRadioPorts($new_record, true);
|
||||
$this->configuration->writeConfiguration($new_record);
|
||||
|
||||
|
|
Loading…
Reference in New Issue