Skip to content
Snippets Groups Projects
Commit 79120e23 authored by Gaus Surahman's avatar Gaus Surahman Committed by Gaus Surahman
Browse files

Issue #3393539 by gausarts, jghyde, Striknin: Not compatible anymore with Drupal 8

parent d871546d
Branches
Tags
No related merge requests found
Pipeline #29839 passed
Blazy 8.x-2.0-dev, 2023-10-13
------------------------------
- Issue #3393539 by gausarts, jghyde, Striknin: Not compatible anymore with
Drupal 8.
Blazy 8.x-2.0-dev, 2023-10-08
------------------------------
- Added Blazy Title formatter with sub-title.
......
......@@ -166,3 +166,10 @@ function blazy_post_update_added_formatter_blazy_entity() {
function blazy_post_update_added_blazy_media_service() {
// Empty hook to clear caches.
}
/**
* Removed file.repository service from blazy.svg for D9.3, see #3393539.
*/
function blazy_post_update_remove_file_repository_service() {
// Empty hook to clear caches.
}
......@@ -50,7 +50,8 @@ services:
blazy.svg:
class: Drupal\blazy\Media\Svg\Svg
arguments: ['@file_system', '@file.repository', '@image.factory', '@logger.factory']
# @todo arguments: ['@file_system', '@file.repository', '@image.factory', '@logger.factory']
arguments: ['@file_system', '@image.factory', '@logger.factory']
blazy.admin.base:
abstract: true
......
......@@ -60,12 +60,12 @@ class Svg implements SvgInterface {
*/
public function __construct(
FileSystemInterface $file_system,
FileRepository $file_repository,
// @todo FileRepository $file_repository,
ImageFactory $image_factory,
LoggerChannelFactoryInterface $logger
) {
$this->fileSystem = $file_system;
$this->fileRepository = $file_repository;
// @todo $this->fileRepository = $file_repository;
$this->imageFactory = $image_factory;
$this->logger = $logger->get('image');
}
......@@ -76,7 +76,7 @@ class Svg implements SvgInterface {
public static function create(ContainerInterface $container) {
return new static(
$container->get('file_system'),
$container->get('file.repository'),
// @todo $container->get('file.repository'),
$container->get('image.factory'),
$container->get('logger.factory')
);
......@@ -93,6 +93,10 @@ class Svg implements SvgInterface {
* {@inheritdoc}
*/
public function fileRepository(): FileRepository {
// @todo remove when min D9.3.
if (!isset($this->fileRepository)) {
$this->fileRepository = Internals::service('file.repository');
}
return $this->fileRepository;
}
......
......@@ -29,7 +29,7 @@ interface SkinManagerBaseInterface extends MapperInterface {
* @param string $id
* The plugin id.
*
* @return object
* @return \Drupal\blazy\Plugin\SkinPluginInterface
* Return instance of BlazySkin.
*/
public function load($id): SkinPluginInterface;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment