If you look at

 if (!empty($this->live_preview)) {
      $cache = FALSE;
    }
    else {
      $cache = $this->display_handler->getPlugin('cache');
    }

      if ($cache) {
        $cache->cache_start();
      }


    if ($cache) {
      $cache->post_render($this->display_handler->output);
    }

you will see that all of the ifs could be replace by using none, if we are in the live preview of a view.

CommentFileSizeAuthor
#4 core-1809222-4.patch2.03 KBdawehner
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

xjm’s picture

Assigned: Unassigned » xjm
xjm’s picture

Project: Views (for Drupal 7) » VDC
Version: 8.x-3.x-dev »
Status: Active » Postponed

Postponing this until after our merge.

xjm’s picture

Project: VDC » Drupal core
Version: » 8.x-dev
Component: Code » views.module
Assigned: xjm » Unassigned
Status: Postponed » Active
dawehner’s picture

Status: Active » Needs review
FileSize
2.03 KB

Added also some documentation on the cache/None.php plugin.

damiankloip’s picture

Status: Needs review » Reviewed & tested by the community

This patch looks fine.

++ for consistency, and always having a cache plugin of some sort.

catch’s picture

Status: Reviewed & tested by the community » Fixed

This looks fair enough, committed/pushed to 8.x.

Automatically closed -- issue fixed for 2 weeks with no activity.