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:
Diffstat (limited to 'plugins/Dashboard/Controller.php')
-rw-r--r--plugins/Dashboard/Controller.php12
1 files changed, 7 insertions, 5 deletions
diff --git a/plugins/Dashboard/Controller.php b/plugins/Dashboard/Controller.php
index 639f279a74..670de08245 100644
--- a/plugins/Dashboard/Controller.php
+++ b/plugins/Dashboard/Controller.php
@@ -127,12 +127,14 @@ class Piwik_Dashboard_Controller extends Piwik_Controller
{
$layout = $this->getLayoutForUser(Piwik::getCurrentUserLogin(),$idDashboard);
}
+ if(!empty($layout))
+ {
+ // layout was JSON.stringified
+ $layout = html_entity_decode($layout);
+ $layout = str_replace("\\\"", "\"", $layout);
- // layout was JSON.stringified
- $layout = html_entity_decode($layout);
- $layout = str_replace("\\\"", "\"", $layout);
-
- $layout = $this->removeDisabledPluginFromLayout($layout);
+ $layout = $this->removeDisabledPluginFromLayout($layout);
+ }
return $layout;
}