You are here

public function SecuritytxtController::__construct in Security.txt 8

Construct a new SecuritytxtController.

Parameters

\Drupal\securitytxt\SecuritytxtSerializer $serializer: The Securitytxt serializer.

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The factory for configuration objects.

File

src/Controller/SecuritytxtController.php, line 38

Class

SecuritytxtController
Controller routines for securitytxt routes.

Namespace

Drupal\securitytxt\Controller

Code

public function __construct(SecuritytxtSerializer $serializer, ConfigFactoryInterface $config_factory) {
  $this->serializer = $serializer;
  $this->settings = $config_factory
    ->get('securitytxt.settings');
}