Skip to content
Snippets Groups Projects
Commit 754bdfe6 authored by Jess's avatar Jess
Browse files

Issue #2846782 followup by xjm: Add inline documentation for the fix.

parent d35eacbd
No related branches found
No related tags found
No related merge requests found
...@@ -344,7 +344,9 @@ protected function getBulkOptions($filtered = TRUE) { ...@@ -344,7 +344,9 @@ protected function getBulkOptions($filtered = TRUE) {
*/ */
public function viewsFormSubmit(&$form, FormStateInterface $form_state) { public function viewsFormSubmit(&$form, FormStateInterface $form_state) {
if ($form_state->get('step') == 'views_form_views_form') { if ($form_state->get('step') == 'views_form_views_form') {
// Filter only selected checkboxes. // Filter only selected checkboxes. Use the actual user input rather than
// the raw form values array, since the site data may change before the
// bulk form is submitted, which can lead to data loss.
$user_input = $form_state->getUserInput(); $user_input = $form_state->getUserInput();
$selected = array_filter($user_input[$this->options['id']]); $selected = array_filter($user_input[$this->options['id']]);
$entities = array(); $entities = array();
......
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