mailboxMapper = $mailboxMapper; $this->jobList = $jobList; } /** * @param IOutput $output * @param Closure $schemaClosure The `\Closure` returns a `ISchemaWrapper` * @param array $options */ public function postSchemaChange(IOutput $output, Closure $schemaClosure, array $options): void { if (!method_exists($this->mailboxMapper, 'findAllIds')) { $output->warning('New Mail code hasn\'t been loaded yet, skipping tag migration. Please run `occ mail:tags:migration-jobs` after the upgrade.'); return; } foreach ($this->mailboxMapper->findAllIds() as $mailboxId) { $this->jobList->add(MigrateImportantJob::class, ['mailboxId' => $mailboxId]); } } }