@@ -185,8 +185,8 @@ discard block |
||
| 185 | 185 | $this->_uncached = $config->get('cache_module_content_uncached'); |
| 186 | 186 | $this->_headers_strategy = $this->get_strategy('cache_module_content_headers_strategy'); |
| 187 | 187 | $this->_headers_strategy_authenticated = $this->get_strategy('cache_module_content_headers_strategy_authenticated'); |
| 188 | - $this->_default_lifetime = (int)$config->get('cache_module_content_default_lifetime'); |
|
| 189 | - $this->_default_lifetime_authenticated = (int)$config->get('cache_module_content_default_lifetime_authenticated'); |
|
| 188 | + $this->_default_lifetime = (int) $config->get('cache_module_content_default_lifetime'); |
|
| 189 | + $this->_default_lifetime_authenticated = (int) $config->get('cache_module_content_default_lifetime_authenticated'); |
|
| 190 | 190 | |
| 191 | 191 | if ($this->_headers_strategy == 'no-cache') { |
| 192 | 192 | $this->no_cache(); |
@@ -485,7 +485,7 @@ discard block |
||
| 485 | 485 | */ |
| 486 | 486 | public function expires($timestamp) |
| 487 | 487 | { |
| 488 | - if ( $this->_expires === null |
|
| 488 | + if ($this->_expires === null |
|
| 489 | 489 | || $this->_expires > $timestamp) { |
| 490 | 490 | $this->_expires = $timestamp; |
| 491 | 491 | } |
@@ -595,7 +595,7 @@ discard block |
||
| 595 | 595 | */ |
| 596 | 596 | public function write_meta_cache($content_id, Request $request, Response $response) |
| 597 | 597 | { |
| 598 | - if ( $this->_uncached |
|
| 598 | + if ($this->_uncached |
|
| 599 | 599 | || $this->_no_cache) { |
| 600 | 600 | return; |
| 601 | 601 | } |
@@ -664,7 +664,7 @@ discard block |
||
| 664 | 664 | |
| 665 | 665 | public function store_dl_content($context, $dl_cache_data, Request $request) |
| 666 | 666 | { |
| 667 | - if ( $this->_no_cache |
|
| 667 | + if ($this->_no_cache |
|
| 668 | 668 | || $this->_uncached) { |
| 669 | 669 | return; |
| 670 | 670 | } |
@@ -730,7 +730,7 @@ discard block |
||
| 730 | 730 | // Add Expiration and Cache Control headers |
| 731 | 731 | $strategy = $this->_headers_strategy; |
| 732 | 732 | $default_lifetime = $this->_default_lifetime; |
| 733 | - if ( midcom::get()->auth->is_valid_user() |
|
| 733 | + if (midcom::get()->auth->is_valid_user() |
|
| 734 | 734 | || midcom_connection::get_user()) { |
| 735 | 735 | $strategy = $this->_headers_strategy_authenticated; |
| 736 | 736 | $default_lifetime = $this->_default_lifetime_authenticated; |