summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Pott2013-06-09 15:10:06 +0100
committerAlex Pott2013-06-09 15:10:06 +0100
commite0db7ebac122d3f15763adf57e0e0603e3d2fc87 (patch)
tree72b73a6f17b30b7b71f21f9ecb40aac4c506d8e7
parent96c82a29139a93ae3e88700dd088945550165583 (diff)
Issue #1999344 by aaronott: Use Symfony Request for edit module.
-rw-r--r--core/modules/edit/lib/Drupal/edit/EditController.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/core/modules/edit/lib/Drupal/edit/EditController.php b/core/modules/edit/lib/Drupal/edit/EditController.php
index 7a7d1a6..ea9b1af 100644
--- a/core/modules/edit/lib/Drupal/edit/EditController.php
+++ b/core/modules/edit/lib/Drupal/edit/EditController.php
@@ -101,10 +101,13 @@ class EditController extends ContainerAware {
* The name of the language for which the field is being edited.
* @param string $view_mode_id
* The view mode the field should be rerendered in.
+ * @param \Symfony\Component\HttpFoundation\Request $request
+ * The current request object containing the search string.
+ *
* @return \Drupal\Core\Ajax\AjaxResponse
* The Ajax response.
*/
- public function fieldForm(EntityInterface $entity, $field_name, $langcode, $view_mode_id) {
+ public function fieldForm(EntityInterface $entity, $field_name, $langcode, $view_mode_id, Request $request) {
$response = new AjaxResponse();
$form_state = array(
@@ -134,7 +137,7 @@ class EditController extends ContainerAware {
}
// When working with a hidden form, we don't want any CSS or JS to be loaded.
- if (isset($_POST['nocssjs']) && $_POST['nocssjs'] === 'true') {
+ if ($request->request->get('nocssjs') === 'true') {
drupal_static_reset('drupal_add_css');
drupal_static_reset('drupal_add_js');
}