Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
8625dfc7
Commit
8625dfc7
authored
Jun 05, 2013
by
alexpott
Browse files
Issue
#2002412
by marlatt, davmorr: Rename Views method cache_set_expire() to cacheSetExpire().
parent
dca8035d
Changes
2
Hide whitespace changes
Inline
Side-by-side
core/modules/views/lib/Drupal/views/Plugin/views/cache/CachePluginBase.php
View file @
8625dfc7
...
...
@@ -105,7 +105,7 @@ protected function cacheExpire($type) { }
* @param $type
* The cache type, either 'query', 'result' or 'output'.
*/
function
cache
_set_e
xpire
(
$type
)
{
protected
function
cache
SetE
xpire
(
$type
)
{
return
CacheBackendInterface
::
CACHE_PERMANENT
;
}
...
...
@@ -126,12 +126,12 @@ public function cacheSet($type) {
'total_rows'
=>
isset
(
$this
->
view
->
total_rows
)
?
$this
->
view
->
total_rows
:
0
,
'current_page'
=>
$this
->
view
->
getCurrentPage
(),
);
cache
(
$this
->
table
)
->
set
(
$this
->
generateResultsKey
(),
$data
,
$this
->
cache
_set_e
xpire
(
$type
));
cache
(
$this
->
table
)
->
set
(
$this
->
generateResultsKey
(),
$data
,
$this
->
cache
SetE
xpire
(
$type
));
break
;
case
'output'
:
$this
->
storage
[
'output'
]
=
$this
->
view
->
display_handler
->
output
;
$this
->
gather_headers
();
cache
(
$this
->
table
)
->
set
(
$this
->
generateOutputKey
(),
$this
->
storage
,
$this
->
cache
_set_e
xpire
(
$type
));
cache
(
$this
->
table
)
->
set
(
$this
->
generateOutputKey
(),
$this
->
storage
,
$this
->
cache
SetE
xpire
(
$type
));
break
;
}
}
...
...
core/modules/views/lib/Drupal/views/Plugin/views/cache/Time.php
View file @
8625dfc7
...
...
@@ -118,7 +118,7 @@ protected function cacheExpire($type) {
}
}
function
cache
_set_e
xpire
(
$type
)
{
protected
function
cache
SetE
xpire
(
$type
)
{
$lifespan
=
$this
->
getLifespan
(
$type
);
if
(
$lifespan
)
{
return
time
()
+
$lifespan
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment