core/modules/views/config/schema/views.data_types.schema.yml | 1 + core/modules/views/src/Entity/View.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/core/modules/views/config/schema/views.data_types.schema.yml b/core/modules/views/config/schema/views.data_types.schema.yml index 13b1c04..a1540b6 100644 --- a/core/modules/views/config/schema/views.data_types.schema.yml +++ b/core/modules/views/config/schema/views.data_types.schema.yml @@ -270,6 +270,7 @@ views_display: label: 'Add the field language to the query' cacheability: type: mapping + label: 'Cacheability' mapping: cacheable: type: boolean diff --git a/core/modules/views/src/Entity/View.php b/core/modules/views/src/Entity/View.php index 5d01d25..a6c0b4a 100644 --- a/core/modules/views/src/Entity/View.php +++ b/core/modules/views/src/Entity/View.php @@ -327,7 +327,7 @@ protected function setCacheability() { foreach ($displays as $display_id => $display) { $executable->setDisplay($display_id); - list($display['cacheability']['contexts'], $display['cacheability']['cacheable']) = $executable->getDisplay()->calculateCacheability(); + list($display['cacheability']['cacheable'], $display['cacheability']['contexts']) = $executable->getDisplay()->calculateCacheability(); // Always include at least the language context as there will be most // probable translatable strings in the view output. $display['cacheability']['contexts'][] = 'cache.context.language';