major update

This commit is contained in:
2026-03-04 15:56:58 +01:00
parent 16759a2732
commit 8f4dd5840d
478 changed files with 24313 additions and 8201 deletions

View File

@@ -4,19 +4,20 @@ namespace MintyPHP\Service\Mail;
use MintyPHP\Repository\Mail\MailLogRepository;
use MintyPHP\Service\Settings\SettingGateway;
use MintyPHP\Service\Settings\SettingServicesFactory;
class MailServicesFactory
{
private ?MailLogRepository $mailLogRepository = null;
private ?SettingServicesFactory $settingServicesFactory = null;
private ?SettingGateway $settingGateway = null;
private ?MailService $mailService = null;
private ?MailLogService $mailLogService = null;
public function __construct(
private readonly MailRepositoryFactory $mailRepositoryFactory,
private readonly SettingGateway $settingGateway
) {}
public function createMailLogRepository(): MailLogRepository
{
return $this->mailLogRepository ??= new MailLogRepository();
return $this->mailRepositoryFactory->createMailLogRepository();
}
public function createMailService(): MailService
@@ -34,11 +35,6 @@ class MailServicesFactory
private function createSettingGateway(): SettingGateway
{
return $this->settingGateway ??= $this->settingServicesFactory()->createSettingGateway();
}
private function settingServicesFactory(): SettingServicesFactory
{
return $this->settingServicesFactory ??= new SettingServicesFactory();
return $this->settingGateway;
}
}