You are here

protected function FileTransferAuthorizeForm::runOperation in Drupal 9

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/FileTransfer/Form/FileTransferAuthorizeForm.php \Drupal\Core\FileTransfer\Form\FileTransferAuthorizeForm::runOperation()

Runs the operation specified in 'authorize_operation' session property.

Parameters

$filetransfer: The FileTransfer object to use for running the operation.

Return value

\Symfony\Component\HttpFoundation\Response|null The result of running the operation. If this is an instance of \Symfony\Component\HttpFoundation\Response the calling code should use that response for the current page request.

1 call to FileTransferAuthorizeForm::runOperation()
FileTransferAuthorizeForm::submitForm in core/lib/Drupal/Core/FileTransfer/Form/FileTransferAuthorizeForm.php
Form submission handler.

File

core/lib/Drupal/Core/FileTransfer/Form/FileTransferAuthorizeForm.php, line 320

Class

FileTransferAuthorizeForm
Provides the file transfer authorization form.

Namespace

Drupal\Core\FileTransfer\Form

Code

protected function runOperation($filetransfer) {
  $operation = $this
    ->getRequest()
    ->getSession()
    ->remove('authorize_operation');
  require_once $operation['file'];
  return call_user_func_array($operation['callback'], array_merge([
    $filetransfer,
  ], $operation['arguments']));
}