websiteRepository = $websiteRepository; } /** * @inheritdoc */ public function toOptionArray(): array { $websites = []; foreach ($this->websiteRepository->getList() as $website) { if ($website->getCode() === WebsiteInterface::ADMIN_CODE) { continue; } $websites[] = [ 'value' => $website->getCode(), 'label' => $website->getName(), ]; } return $websites; } }