Skip to content

Commit

Permalink
Only clearCache() if required
Browse files Browse the repository at this point in the history
Check if Empty Cache was checked, and only clearCache() if true.
  • Loading branch information
dannevang committed Apr 30, 2013
1 parent 0e21730 commit 1e5d980
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions core/components/babel/model/babel/babel.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,10 @@ public function sychronizeTvs($resourceId) {
}
$tv->save();
}

$this->modx->cacheManager->clearCache();
//Check if clearCache is set, and clear cache if is.
if($clearCache) {
$this->modx->cacheManager->clearCache();
}
}

/**
Expand Down Expand Up @@ -470,4 +472,4 @@ private function _getTplChunk($name,$suffix = '.chunk.tpl') {
return $chunk;
}

}
}

0 comments on commit 1e5d980

Please sign in to comment.