Skip to content

Commit

Permalink
Add some logging to help see where data is being changed.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrubinsk committed Oct 16, 2013
1 parent b7350cb commit f1105f8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions framework/ActiveSync/lib/Horde/ActiveSync/SyncCache.php
Expand Up @@ -235,6 +235,7 @@ public function countCollections()
*/
public function clearCollections()
{
$this->_logger->info('Clearing collections data from cache.');
$this->_data['collections'] = array();
$this->_dirty['collections'] = true;
}
Expand Down Expand Up @@ -414,6 +415,10 @@ public function addCollection(array $collection)
public function removeCollection($id, $purge = true)
{
if (!$purge) {
$this->_logger->info(sprintf(
'Removing collection %s from SyncCache.',
$id)
);
unset($this->_data['collections'][$id]);
$this->_dirty['collections'] = true;
} elseif (!empty($this->_data['collections'][$id])) {
Expand All @@ -440,6 +445,7 @@ public function updateWindowSize($id, $windowsize)
*/
public function clearCollectionKeys()
{
$this->_logger->info('Clearing all collection synckeys from the cache.');
foreach ($this->_data['collections'] as $id => &$c) {
unset($c['synckey']);
}
Expand Down

0 comments on commit f1105f8

Please sign in to comment.