Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordiosmosis <diosmosis@users.noreply.github.com>2020-09-11 04:19:41 +0300
committerGitHub <noreply@github.com>2020-09-11 04:19:41 +0300
commit6b70e8cc7a12e596bfa08e35db52531ce989c2f2 (patch)
tree151cda62467fb0c5266adb6e901c3bd50499fb2b /plugins/SitesManager
parentd01085cec58a437e30b0dd4b149c52fc3e19abaa (diff)
Add methods to remove invalidations. (#16400)
* Add methods to remove invalidations. * Add check if site exists to beginning of queue consumers loop to find archive data * Delete invalidations w/ no site in task and for site when deleting. * fix test * fix test * another test fix
Diffstat (limited to 'plugins/SitesManager')
-rw-r--r--plugins/SitesManager/API.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/SitesManager/API.php b/plugins/SitesManager/API.php
index ef6f85c8ca..d52003a71f 100644
--- a/plugins/SitesManager/API.php
+++ b/plugins/SitesManager/API.php
@@ -34,6 +34,7 @@ use Piwik\Tracker\TrackerCodeGenerator;
use Piwik\Measurable\Type;
use Piwik\Url;
use Piwik\UrlHelper;
+use Piwik\DataAccess\Model as CoreModel;
/**
* The SitesManager API gives you full control on Websites in Matomo (create, update and delete), and many methods to retrieve websites based on various attributes.
@@ -782,6 +783,9 @@ class API extends \Piwik\Plugin\API
$this->getModel()->deleteSite($idSite);
+ $coreModel = new CoreModel();
+ $coreModel->deleteInvalidationsForSites([$idSite]);
+
/**
* Triggered after a site has been deleted.
*