From 34b94c8c3a49f8eb4503b5a8044d78aac6829b2e Mon Sep 17 00:00:00 2001 From: Nathaniel Catchpole <catch@35733.no-reply.drupal.org> Date: Mon, 7 Jan 2019 11:34:38 +0000 Subject: [PATCH] Issue #2978922 by brathbone, philipnorton42, msankhala, hardikpandya, alexpott, siliconmeadow: Improve batch_process() documentation --- core/includes/form.inc | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/core/includes/form.inc b/core/includes/form.inc index 95c1564eded4..ec6b2e8f30e0 100644 --- a/core/includes/form.inc +++ b/core/includes/form.inc @@ -792,18 +792,18 @@ function batch_set($batch_definition) { * Form API takes care of batches that were set during form submission. * * @param \Drupal\Core\Url|string $redirect - * (optional) Either path or Url object to redirect to when the batch has - * finished processing. Note that to simply force a batch to (conditionally) - * redirect to a custom location after it is finished processing but to - * otherwise allow the standard form API batch handling to occur, it is not - * necessary to call batch_process() and use this parameter. Instead, make - * the batch 'finished' callback return an instance of - * \Symfony\Component\HttpFoundation\RedirectResponse, which will be used + * (optional) Either a path or Url object to redirect to when the batch has + * finished processing. For example, to redirect users to the home page, use + * '<front>'. If you wish to allow standard form API batch handling to occur + * and force the user to be redirected to a custom location after the batch + * has finished processing, you do not need to use batch_process() and this + * parameter. Instead, make the batch 'finished' callback return an instance + * of \Symfony\Component\HttpFoundation\RedirectResponse, which will be used * automatically by the standard batch processing pipeline (and which takes - * precedence over this parameter). - * User will be redirected to the page that started the batch if this argument - * is omitted and no redirect response was returned by the 'finished' - * callback. Any query arguments will be automatically persisted. + * precedence over this parameter). If this parameter is omitted and no + * redirect response was returned by the 'finished' callback, the user will + * be redirected to the page that started the batch. Any query arguments will + * be automatically persisted. * @param \Drupal\Core\Url $url * (optional) URL of the batch processing page. Should only be used for * separate scripts like update.php. -- GitLab