Skip to content

Commit

Permalink
fixed: widget cache clear took too long
Browse files Browse the repository at this point in the history
  • Loading branch information
jeabakker committed Mar 24, 2016
1 parent b1c1327 commit 03a43ee
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions classes/ColdTrick/WidgetManager/Cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,17 @@ public static function resetWidgetsCache($event, $type, $object) {
'type' => 'object',
'subtype' => 'widget',
'limit' => false,
'private_setting_name' => 'widget_manager_cached_data',
'private_setting_name_value_pairs' => [
'name' => 'widget_manager_cached_data',
'value' => 0,
'operand' => '>',
],
]);

$batch->setIncrementOffset(false);

foreach ($batch as $entity) {
$entity->widget_manager_cached_data = null;
$entity->widget_manager_cached_data = 0;
}

elgg_set_ignore_access($ia);
Expand Down

0 comments on commit 03a43ee

Please sign in to comment.