diff options
-rw-r--r-- | plugins/CoreAdminHome/Tasks.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/CoreAdminHome/Tasks.php b/plugins/CoreAdminHome/Tasks.php index ff3ae6497f..97180241cc 100644 --- a/plugins/CoreAdminHome/Tasks.php +++ b/plugins/CoreAdminHome/Tasks.php @@ -277,6 +277,12 @@ class Tasks extends \Piwik\Plugin\Tasks if (empty($purgedDates[$yesterdayStr])) { $this->archivePurger->purgeInvalidatedArchivesFrom($yesterday); } + + // handle year start table + $yearStart = $today->toString('Y-01'); + if (empty($purgedDates[$yearStart])) { + $this->archivePurger->purgeInvalidatedArchivesFrom(Date::factory($yearStart . '-01')); + } } public function optimizeArchiveTable() |