Skip to content
Snippets Groups Projects
Commit d9002c19 authored by Hardik Pandya's avatar Hardik Pandya Committed by Liam Morland
Browse files

Issue #3347444: Replace use of FileSystem with FileSystemInterface

parent 0d574a55
No related branches found
No related tags found
No related merge requests found
......@@ -28,7 +28,7 @@ class LocalServerPdfBackend extends PdfBackendBase implements ContainerFactoryPl
/**
* The file system.
*
* @var \Drupal\Core\File\FileSystem
* @var \Drupal\Core\File\FileSystemInterface
*/
protected $fileSystem;
......
......@@ -3,7 +3,6 @@
namespace Drupal\fillpdf\Plugin\PdfBackend;
use Drupal\Core\Entity\EntityTypeManagerInterface;
use Drupal\Core\File\FileSystem;
use Drupal\Core\File\FileSystemInterface;
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
use Drupal\file\FileInterface;
......@@ -35,7 +34,7 @@ class PdftkPdfBackend extends PdfBackendBase implements ContainerFactoryPluginIn
/**
* The file system.
*
* @var \Drupal\Core\File\FileSystem
* @var \Drupal\Core\File\FileSystemInterface
*/
protected $fileSystem;
......@@ -62,14 +61,14 @@ class PdftkPdfBackend extends PdfBackendBase implements ContainerFactoryPluginIn
* The plugin_id for the plugin instance.
* @param array $plugin_definition
* The plugin implementation definition.
* @param \Drupal\Core\File\FileSystem $file_system
* @param \Drupal\Core\File\FileSystemInterface $file_system
* The file system.
* @param \Drupal\fillpdf\ShellManager $shell_manager
* The FillPDF shell manager.
* @param \Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager
* The entity type manager.
*/
public function __construct(array $configuration, $plugin_id, array $plugin_definition, FileSystem $file_system, ShellManager $shell_manager, EntityTypeManagerInterface $entity_type_manager) {
public function __construct(array $configuration, $plugin_id, array $plugin_definition, FileSystemInterface $file_system, ShellManager $shell_manager, EntityTypeManagerInterface $entity_type_manager) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->fileSystem = $file_system;
$this->shellManager = $shell_manager;
......
......@@ -146,7 +146,7 @@ trait TestFillPdfTrait {
* The absolute locale filepath or FALSE on failure.
*/
protected function getTestPdfPath($filename) {
/** @var \Drupal\Core\File\FileSystem $file_system */
/** @var \Drupal\Core\File\FileSystemInterface $file_system */
$file_system = $this->container->get('file_system');
return $file_system->realpath(\Drupal::service('extension.list.module')->getPath('fillpdf') . '/tests/modules/fillpdf_test/files/' . $filename);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment