Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Duplicated method chains, removed commented line in admin generator u…

…pdateAction
  • Loading branch information...
commit a52197ae652d63e3dfa06e249524028770b45f8a 1 parent 5fb32f4
@fruit authored
View
4 README.markdown
@@ -49,7 +49,7 @@ are not (atomic counter).
## New in v4.0.0:
- * Update: Many changes in API
+ * Update: Many API changes
* New: Admin generator "cachable" (see more info in README_ADVANCED)
* New: Cascading tag deletion through the model relations [GH-6](https://github.com/fruit/sfCacheTaggingPlugin/issues#issue/6)
* New: Option ``invalidateCollectionVersionByChangingColumns`` to setup ``Cachetaggable`` behavior (see below) [GH-8](https://github.com/fruit/sfCacheTaggingPlugin/issues#issue/8)
@@ -105,7 +105,7 @@ And after, rebuild your models:
class: sfFileTaggingCache
param:
automatic_cleaning_factor: 0
- cache_dir: %SF_CACHE_DIR%/sf_tag_cache/data
+ cache_dir: %SF_CACHE_DIR%/sf_tag_cache
logger:
class: sfFileCacheTagLogger
param:
View
2  data/generator/sfDoctrineModule/cachable/parts/updateAction.php
@@ -4,6 +4,4 @@ public function executeUpdate(sfWebRequest $request)
$this->form = $this->configuration->getForm($this-><?php echo $this->getSingularName() ?>);
$this->processForm($request, $this->form);
-
- // $this->setTemplate('edit');
}
View
26 lib/view/sfViewCacheTagManager.class.php
@@ -435,10 +435,10 @@ public function setPageCache ($uri)
self::NAMESPACE_PAGE
);
+ $response = $this->getContext()->getResponse();
+
// save content in cache
- $saved = $this->set(
- $this->getContext()->getResponse(), $uri, $contentTags
- );
+ $saved = $this->set($response, $uri, $contentTags);
if ($saved && sfConfig::get('sf_web_debug'))
{
@@ -449,16 +449,16 @@ public function setPageCache ($uri)
$this,
'view.cache.filter_content',
array(
- 'response' => $this->getContext()->getResponse(),
+ 'response' => $response,
'uri' => $uri,
'new' => true
)
),
- $this->getContext()->getResponse()->getContent()
+ $response->getContent()
)
->getReturnValue();
- $this->getContext()->getResponse()->setContent($content);
+ $response->setContent($content);
}
}
@@ -488,10 +488,12 @@ public function setPartialCache ($module, $action, $cacheKey, $content)
$contentTags = $tagHandler->getContentTags($namespace);
+ $response = $this->getContext()->getResponse();
+
$saved = $this->set(
array(
'content' => $content,
- 'response' => serialize($this->getContext()->getResponse()),
+ 'response' => serialize($response),
),
$uri,
$contentTags
@@ -506,7 +508,7 @@ public function setPartialCache ($module, $action, $cacheKey, $content)
$this,
'view.cache.filter_content',
array(
- 'response' => $this->getContext()->getResponse(),
+ 'response' => $response,
'uri' => $uri,
'new' => true,
)
@@ -635,6 +637,8 @@ public function getPageCache ($uri)
{
$this->getContext()->setResponse($cachedResponse);
+ $response = $this->getContext()->getResponse();
+
if (sfConfig::get('sf_web_debug'))
{
$content = $this
@@ -644,16 +648,16 @@ public function getPageCache ($uri)
$this,
'view.cache.filter_content',
array(
- 'response' => $this->getContext()->getResponse(),
+ 'response' => $response,
'uri' => $uri,
'new' => false,
)
),
- $this->getContext()->getResponse()->getContent()
+ $response->getContent()
)
->getReturnValue();
- $this->getContext()->getResponse()->setContent($content);
+ $response->setContent($content);
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.