Browse Source

Use FileUrlGeneratorInterface (#996)

* Use FileUrlGeneratorInterface

* Use FileUrlGeneratorInterface
pull/999/head
Seth Shaw 10 months ago committed by GitHub
parent
commit
c6341649ca
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      src/Plugin/Field/FieldFormatter/IslandoraImageFormatter.php

6
src/Plugin/Field/FieldFormatter/IslandoraImageFormatter.php

@ -5,7 +5,7 @@ namespace Drupal\islandora\Plugin\Field\FieldFormatter;
use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Entity\EntityStorageInterface;
use Drupal\Core\Field\FieldDefinitionInterface; use Drupal\Core\Field\FieldDefinitionInterface;
use Drupal\Core\Field\FieldItemListInterface; use Drupal\Core\Field\FieldItemListInterface;
use Drupal\Core\File\FileUrlGenerator; use Drupal\Core\File\FileUrlGeneratorInterface;
use Drupal\Core\Session\AccountInterface; use Drupal\Core\Session\AccountInterface;
use Drupal\image\Plugin\Field\FieldFormatter\ImageFormatter; use Drupal\image\Plugin\Field\FieldFormatter\ImageFormatter;
use Drupal\islandora\IslandoraUtils; use Drupal\islandora\IslandoraUtils;
@ -57,7 +57,7 @@ class IslandoraImageFormatter extends ImageFormatter {
* The image style storage. * The image style storage.
* @param \Drupal\islandora\IslandoraUtils $utils * @param \Drupal\islandora\IslandoraUtils $utils
* Islandora utils. * Islandora utils.
* @param \Drupal\Core\File\FileUrlGenerator $file_url_generator * @param \Drupal\Core\File\FileUrlGeneratorInterface $file_url_generator
* The File URL Generator. * The File URL Generator.
*/ */
public function __construct( public function __construct(
@ -71,7 +71,7 @@ class IslandoraImageFormatter extends ImageFormatter {
AccountInterface $current_user, AccountInterface $current_user,
EntityStorageInterface $image_style_storage, EntityStorageInterface $image_style_storage,
IslandoraUtils $utils, IslandoraUtils $utils,
FileUrlGenerator $file_url_generator FileUrlGeneratorInterface $file_url_generator
) { ) {
parent::__construct( parent::__construct(
$plugin_id, $plugin_id,

Loading…
Cancel
Save