diff options
author | diosmosis <diosmosis@users.noreply.github.com> | 2020-09-21 01:30:00 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-21 01:30:00 +0300 |
commit | 1cb41a757e96e5a0c19da9a0deaad7dc5593c759 (patch) | |
tree | cb81217f03514dab2ac9ffc3e229d46bd3d93286 /plugins/CoreAdminHome | |
parent | 62fcad39c4f0c5d8c0d75b2456a4ac07f7b106a5 (diff) |
Add extra check for queue consumer to prevent duplicates and add duplicate check in tests. (#16406)
Diffstat (limited to 'plugins/CoreAdminHome')
-rw-r--r-- | plugins/CoreAdminHome/Tasks.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/plugins/CoreAdminHome/Tasks.php b/plugins/CoreAdminHome/Tasks.php index 9cccf23aba..eb76a8c6f0 100644 --- a/plugins/CoreAdminHome/Tasks.php +++ b/plugins/CoreAdminHome/Tasks.php @@ -112,8 +112,11 @@ class Tasks extends \Piwik\Plugin\Tasks return; } - $cronArchive = new CronArchive(); - $cronArchive->invalidateArchivedReportsForSitesThatNeedToBeArchivedAgain(); + $idSites = Request::processRequest('SitesManager.getAllSitesId'); + foreach ($idSites as $idSite) { + $cronArchive = new CronArchive(); + $cronArchive->invalidateArchivedReportsForSitesThatNeedToBeArchivedAgain($idSite); + } } private function scheduleTrackingCodeReminderChecks() |