diff --git a/core/modules/system/tests/modules/form_test/form_test.module b/core/modules/system/tests/modules/form_test/form_test.module index 730a972..a932868 100644 --- a/core/modules/system/tests/modules/form_test/form_test.module +++ b/core/modules/system/tests/modules/form_test/form_test.module @@ -605,7 +605,7 @@ function form_test_storage_form($form, &$form_state) { '#value' => 'Save', ); - if (\Drupal::request()->request->has('cache')) { + if (\Drupal::request()->get('cache')) { // Manually activate caching, so we can test that the storage keeps working // when it's enabled. $form_state['cache'] = TRUE; @@ -624,7 +624,7 @@ function form_test_storage_element_validate_value_cached($element, &$form_state) // This presumes that another submitted form value triggers a validation error // elsewhere in the form. Form API should still update the cached form storage // though. - if (\Drupal::request()->request->has('cache') && $form_state['values']['value'] == 'change_title') { + if (\Drupal::request()->get('cache') && $form_state['values']['value'] == 'change_title') { $form_state['storage']['thing']['changed'] = TRUE; } } @@ -1760,7 +1760,7 @@ function form_test_state_persist_submit($form, &$form_state) { function form_test_form_form_test_state_persist_alter(&$form, &$form_state) { // Simulate a form alter implementation inserting form elements that enable // caching of the form, e.g. elements having #ajax. - if (\Drupal::request()->request->has('cache')) { + if (\Drupal::request()->get('cache')) { $form_state['cache'] = TRUE; } }