mglaman / drupal-change-record-triage

Used to triage Drupal change records to ensure phpstan-drupal, drupal-rector, and upgrade_status have appropriate issues.
MIT License
6 stars 0 forks source link

FileUploadResource now uses FileUploadHandler #785

Open github-actions[bot] opened 1 month ago

github-actions[bot] commented 1 month ago

https://www.drupal.org/node/3402032

Introduced in branch/version: 10.3.x / 10.3.0

\Drupal\file\Plugin\rest\resource\FileUploadResource no longer duplicates file upload logic, and re-uses the \Drupal\file\Upload\FileUploadHandler.

As such the constructor for FileUploadResource has changed.

Before:

public function __construct(
  array $configuration, 
  $plugin_id, 
  $plugin_definition, 
  $serializer_formats, 
  LoggerInterface $logger, 
  FileSystemInterface $file_system, 
  EntityTypeManagerInterface $entity_type_manager, 
  EntityFieldManagerInterface $entity_field_manager, 
  AccountInterface $current_user, 
  $mime_type_guesser, 
  Token $token, 
  LockBackendInterface $lock, 
  Config $system_file_config, 
  EventDispatcherInterface $event_dispatcher, 
  FileValidatorInterface $file_validator = NULL,
)

After:

public function __construct(
    array $configuration,
    $plugin_id,
    $plugin_definition,
    $serializer_formats,
    LoggerInterface $logger,
    protected FileSystemInterface $fileSystem,
    protected EntityTypeManagerInterface $entityTypeManager,
    protected EntityFieldManagerInterface $entityFieldManager,
    protected FileValidatorInterface $fileValidator,
    protected InputStreamFileWriterInterface $inputStreamFileWriter,
    protected FileUploadHandler $fileUploadHandler,
)
bbrala commented 1 month ago

Dont see usage:

https://git.drupalcode.org/search?group_id=2&scope=blobs&search=-path%3Acore+-path%3Avendor+-path%3Adocroot+-path%3Aweb+-path%3Aprofiles+-path%3Asites+%22new+FileUploadResource%22