diff options
author | Thomas Steur <thomas.steur@gmail.com> | 2015-02-09 02:14:26 +0300 |
---|---|---|
committer | Thomas Steur <thomas.steur@gmail.com> | 2015-02-10 03:44:59 +0300 |
commit | 51391ddcd49dd1dce4e83c86bbee06c666a27f34 (patch) | |
tree | f39326a89f0a1035b87eaa2adba0ae95dae6981a | |
parent | 6c0db645eafb257eff599d8c85f99537df34d379 (diff) |
refs #6809 make sure we do not set sites if they are already set
-rwxr-xr-x | plugins/MultiSites/API.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/MultiSites/API.php b/plugins/MultiSites/API.php index 144ef15d7c..55fd6b3fce 100755 --- a/plugins/MultiSites/API.php +++ b/plugins/MultiSites/API.php @@ -138,6 +138,8 @@ class API extends \Piwik\Plugin\API // added because caller could overwrite these 'serialize' => 0, 'format' => 'original')); + + Site::setSitesFromArray($sitesToProblablyAdd); } return $sitesToProblablyAdd; @@ -185,7 +187,6 @@ class API extends \Piwik\Plugin\API { $idSites = array(); if (!empty($sitesToProblablyAdd)) { - Site::setSitesFromArray($sitesToProblablyAdd); foreach ($sitesToProblablyAdd as $site) { $idSites[] = $site['idsite']; } |