diff -u b/src/Hook/PagerMetadataHooks.php b/src/Hook/PagerMetadataHooks.php --- b/src/Hook/PagerMetadataHooks.php +++ b/src/Hook/PagerMetadataHooks.php @@ -17,7 +17,7 @@ * Implements hook_page_attachments_alter(). */ #[Hook('page_attachments_alter')] - public static function pageAttachmentsAlter(array &$attachments) { + public function pageAttachmentsAlter(array &$attachments) { $cache = CacheableMetadata::createFromRenderArray($attachments); if (Settings::get('pager_metadata_alter_canonical', TRUE)) { foreach ($attachments['#attached']['html_head'] as &$attachment) { @@ -47,7 +47,7 @@ * Implements hook_preprocess_HOOK(). */ #[Hook('preprocess_pager')] - public static function preprocessPager(&$pager) { + public function preprocessPager(&$pager) { _pager_metadata_relations_to_head($pager); } @@ -55,7 +55,7 @@ * Implements hook_preprocess_HOOK(). */ #[Hook('preprocess_views_infinite_scroll_pager')] - public static function preprocessViewsInfiniteScrollPager(&$pager) { + public function preprocessViewsInfiniteScrollPager(&$pager) { _pager_metadata_relations_to_head($pager); } @@ -65,7 +65,7 @@ * @link https://www.drupal.org/project/drupal/issues/2769953#comment-12561253 */ #[Hook('block_build_alter')] - public static function blockBuildAlter(array &$build, BlockPluginInterface $block) { + public function blockBuildAlter(array &$build, BlockPluginInterface $block) { if ($block->getBaseId() == 'views_block') { // To make sure the pager preprocess can still insert something the head. $build['#create_placeholder'] = FALSE;