Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/Form/AppearanceForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace Drupal\ucb_site_configuration\Form;

use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\TypedConfigManagerInterface;
use Drupal\Core\File\FileSystemInterface;
use Drupal\Core\Form\ConfigFormBase;
use Drupal\Core\Form\FormStateInterface;
Expand Down Expand Up @@ -50,8 +51,8 @@ class AppearanceForm extends ConfigFormBase {
* @param \Drupal\ucb_site_configuration\SiteConfiguration $service
* The site configuration service defined in this module.
*/
public function __construct(ConfigFactoryInterface $config_factory, FileSystemInterface $file_system, AccountInterface $user, SiteConfiguration $service) {
parent::__construct($config_factory);
public function __construct(ConfigFactoryInterface $config_factory, TypedConfigManagerInterface $typed_config_manager, FileSystemInterface $file_system, AccountInterface $user, SiteConfiguration $service) {
parent::__construct($config_factory, $typed_config_manager);
$this->fileSystem = $file_system;
$this->user = $user;
$this->service = $service;
Expand All @@ -68,6 +69,7 @@ public function __construct(ConfigFactoryInterface $config_factory, FileSystemIn
public static function create(ContainerInterface $container) {
return new static(
$container->get('config.factory'),
$container->get('config.typed'),
$container->get('file_system'),
$container->get('current_user'),
$container->get('ucb_site_configuration')
Expand Down
6 changes: 4 additions & 2 deletions src/Form/ContentTypesForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace Drupal\ucb_site_configuration\Form;

use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\TypedConfigManagerInterface;
use Drupal\Core\Entity\EntityTypeManagerInterface;
use Drupal\Core\Form\ConfigFormBase;
use Drupal\Core\Form\FormStateInterface;
Expand Down Expand Up @@ -38,8 +39,8 @@ class ContentTypesForm extends ConfigFormBase {
* @param \Drupal\ucb_site_configuration\SiteConfiguration $service
* The site configuration service defined in this module.
*/
public function __construct(ConfigFactoryInterface $config_factory, EntityTypeManagerInterface $entityTypeManager, SiteConfiguration $service) {
parent::__construct($config_factory);
public function __construct(ConfigFactoryInterface $config_factory, TypedConfigManagerInterface $typed_config_manager, EntityTypeManagerInterface $entityTypeManager, SiteConfiguration $service) {
parent::__construct($config_factory, $typed_config_manager);
$this->entityTypeManager = $entityTypeManager;
$this->service = $service;
}
Expand All @@ -55,6 +56,7 @@ public function __construct(ConfigFactoryInterface $config_factory, EntityTypeMa
public static function create(ContainerInterface $container) {
return new static(
$container->get('config.factory'),
$container->get('config.typed'),
$container->get('entity_type.manager'),
$container->get('ucb_site_configuration')
);
Expand Down
6 changes: 4 additions & 2 deletions src/Form/GeneralForm.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace Drupal\ucb_site_configuration\Form;

use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\TypedConfigManagerInterface;
use Drupal\Core\Form\ConfigFormBase;
use Drupal\Core\Form\FormStateInterface;
use Drupal\Core\Path\PathValidatorInterface;
Expand Down Expand Up @@ -68,8 +69,8 @@ class GeneralForm extends ConfigFormBase {
* @param \Drupal\ucb_site_configuration\SiteConfiguration $service
* The site configuration service defined in this module.
*/
public function __construct(ConfigFactoryInterface $config_factory, AliasManagerInterface $alias_manager, PathValidatorInterface $path_validator, RequestContext $request_context, AccountInterface $user, SiteConfiguration $service) {
parent::__construct($config_factory);
public function __construct(ConfigFactoryInterface $config_factory, TypedConfigManagerInterface $typed_config_manager, AliasManagerInterface $alias_manager, PathValidatorInterface $path_validator, RequestContext $request_context, AccountInterface $user, SiteConfiguration $service) {
parent::__construct($config_factory, $typed_config_manager);
$this->aliasManager = $alias_manager;
$this->pathValidator = $path_validator;
$this->requestContext = $request_context;
Expand All @@ -88,6 +89,7 @@ public function __construct(ConfigFactoryInterface $config_factory, AliasManager
public static function create(ContainerInterface $container) {
return new static(
$container->get('config.factory'),
$container->get('config.typed'),
$container->get('path_alias.manager'),
$container->get('path.validator'),
$container->get('router.request_context'),
Expand Down
2 changes: 1 addition & 1 deletion src/SiteConfiguration.php
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ public function attachPeopleListConfiguration(array &$variables) {
* A node to match includes that are for specific content. If null, only
* sitewide includes will be attached.
*/
public function attachExternalServiceIncludes(array &$attachments, NodeInterface $node = NULL) {
public function attachExternalServiceIncludes(array &$attachments, ?NodeInterface $node = NULL) {
$storage = $this->entityTypeManager->getStorage($this->entityTypeRepository->getEntityTypeFromClass(ExternalServiceInclude::class));
$query = $storage->getQuery('OR')->condition('sitewide', TRUE);
if ($node) {
Expand Down