Skip to content

Instantly share code, notes, and snippets.

@ahebrank
Last active August 25, 2017 14:38
Show Gist options
  • Select an option

  • Save ahebrank/70b98af2f4df3c66c432046ec1558fda to your computer and use it in GitHub Desktop.

Select an option

Save ahebrank/70b98af2f4df3c66c432046ec1558fda to your computer and use it in GitHub Desktop.
8.3.7 Views ajax access API bugfix
diff --git a/core/modules/views/src/Controller/ViewAjaxController.php b/core/modules/views/src/Controller/ViewAjaxController.php
index d204766..2e0ea18 100644
--- a/core/modules/views/src/Controller/ViewAjaxController.php
+++ b/core/modules/views/src/Controller/ViewAjaxController.php
@@ -142,7 +142,7 @@ public function ajaxView(Request $request) {
throw new NotFoundHttpException();
}
$view = $this->executableFactory->get($entity);
- if ($view && $view->access($display_id) && $view->setDisplay($display_id) && $view->display_handler->getOption('use_ajax')) {
+ if ($view && $view->access($display_id) && $view->setDisplay($display_id) && $view->display_handler->ajaxEnabled()) {
$response->setView($view);
// Fix the current path for paging.
if (!empty($path)) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment