Added default parameter $reset to allow for incremental rescan.

This commit is contained in:
Thomas Tanghus 2012-07-09 00:14:42 +02:00
parent 6d123e90f3
commit 6116dc6b65
1 changed files with 4 additions and 2 deletions

View File

@ -131,8 +131,10 @@ class OC_VCategories {
* }
* $categories->rescan($objects);
*/
public function rescan($objects, $sync=true) {
$this->categories = array();
public function rescan($objects, $sync=true, $reset=true) {
if($reset === true) {
$this->categories = array();
}
foreach($objects as $object) {
//OC_Log::write('core','OC_VCategories::rescan: '.substr($object, 0, 100).'(...)', OC_Log::DEBUG);
$vobject = OC_VObject::parse($object);