diff --git a/core/modules/image/image.routing.yml b/core/modules/image/image.routing.yml index 419fc71..4b7f7d5 100644 --- a/core/modules/image/image.routing.yml +++ b/core/modules/image/image.routing.yml @@ -15,7 +15,7 @@ image_effect_delete: image_style_private: pattern: '/system/files/styles/{image_style}/{scheme}' defaults: - _controller: '\Drupal\image\Controller\ImageStyleDeliver::deliver' + _controller: '\Drupal\image\Controller\ImageStyleFileService::deliver' requirements: _access: 'TRUE' diff --git a/core/modules/image/lib/Drupal/image/Controller/ImageStyleDeliver.php b/core/modules/image/lib/Drupal/image/Controller/ImageStyleFileService.php similarity index 97% rename from core/modules/image/lib/Drupal/image/Controller/ImageStyleDeliver.php rename to core/modules/image/lib/Drupal/image/Controller/ImageStyleFileService.php index 516e6cc..3ce7582 100644 --- a/core/modules/image/lib/Drupal/image/Controller/ImageStyleDeliver.php +++ b/core/modules/image/lib/Drupal/image/Controller/ImageStyleFileService.php @@ -2,7 +2,7 @@ /** * @file - * Contains \Drupal\image\Controller\ImageStyleController. + * Contains \Drupal\image\Controller\ImageStyleFileService. */ namespace Drupal\image\Controller; @@ -13,7 +13,7 @@ use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Lock\LockBackendInterface; use Drupal\image\ImageStyleInterface; -use Drupal\system\FileController; +use Drupal\system\FileService; use Symfony\Component\DependencyInjection\ContainerInterface; use Symfony\Component\HttpFoundation\BinaryFileResponse; use Symfony\Component\HttpFoundation\Request; @@ -23,7 +23,7 @@ /** * Defines a controller to serve image styles. */ -class ImageStyleDeliver extends FileController implements ControllerInterface { +class ImageStyleFileService extends FileService implements ControllerInterface { /** * The config factory. diff --git a/core/modules/system/lib/Drupal/system/FileController.php b/core/modules/system/lib/Drupal/system/FileService.php similarity index 93% rename from core/modules/system/lib/Drupal/system/FileController.php rename to core/modules/system/lib/Drupal/system/FileService.php index d60e459..d97274e 100644 --- a/core/modules/system/lib/Drupal/system/FileController.php +++ b/core/modules/system/lib/Drupal/system/FileService.php @@ -2,12 +2,11 @@ /** * @file - * Contains \Drupal\system\FileController. + * Contains \Drupal\system\FileService. */ namespace Drupal\system; -use Drupal\Core\Extension\ModuleHandler; use Drupal\Core\Controller\ControllerInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Symfony\Component\DependencyInjection\ContainerInterface; @@ -19,7 +18,7 @@ /** * System file controller. */ -class FileController implements ControllerInterface { +class FileService implements ControllerInterface { /** * The module handler. @@ -72,7 +71,7 @@ public static function create(ContainerInterface $container) { * @return \Symfony\Component\HttpFoundation\BinaryFileResponse * The transferred file as response. */ - public function fileDownload(Request $request, $scheme = 'private') { + public function deliver(Request $request, $scheme = 'private') { $target = $request->query->get('file'); // Merge remaining path arguments into relative file path. $uri = $scheme . '://' . $target; diff --git a/core/modules/system/system.routing.yml b/core/modules/system/system.routing.yml index 2085869..f6a7235 100644 --- a/core/modules/system/system.routing.yml +++ b/core/modules/system/system.routing.yml @@ -147,7 +147,7 @@ system_admin_index: system_files: pattern: '/system/files/{scheme}' defaults: - _controller: 'Drupal\system\FileController::fileDownload' + _controller: 'Drupal\system\FileService::deliver' scheme: private requirements: _access: 'TRUE'