addComponentPath($libraryPath, Priority::LOWEST); // Load config and apply to PHPMailer $mailerCfg = $config->get("mailer"); foreach ($mailerCfg->toArray() as $key => $val) { if (str_contains($key, '()')) { $key = str_replace('()', '', $key); if (is_array($val)) $this->{$key}(...$val); elseif (empty($val)) $this->{$key}(); else $this->{$key}($val); } else $this->{$key} = $val; } } /** * @inheritDoc */ public function getClassesPrefix(): ?string { return null; } /** * @inheritDoc */ public function getSourceDirectory(): ?string { return null; } }