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 <benaka@piwik.pro>2014-10-23 04:27:31 +0400
committerdiosmosis <benaka@piwik.pro>2014-10-23 04:27:49 +0400
commitd15b987848d0d7a42ff5839611827cc64ae6e578 (patch)
tree76df0c491aa501ddde34e6e0d9ef4f956d6bcb39 /core/Tracker/GoalManager.php
parent30521fba799c677d3e332f4c9238b7ab7689b6b3 (diff)
Fixes #6068, correctly decode JSON encoded ec_items query parameter values so escaped HTML is properly handled by tracker. Includes tests and a separate fix to tests:run command (command fails when --options is used w/ a group argument).
Diffstat (limited to 'core/Tracker/GoalManager.php')
-rw-r--r--core/Tracker/GoalManager.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/Tracker/GoalManager.php b/core/Tracker/GoalManager.php
index 27b3a6f48c..9f989df935 100644
--- a/core/Tracker/GoalManager.php
+++ b/core/Tracker/GoalManager.php
@@ -361,7 +361,7 @@ class GoalManager
*/
private function getEcommerceItemsFromRequest()
{
- $items = Common::unsanitizeInputValue($this->request->getParam('ec_items'));
+ $items = $this->request->getParam('ec_items');
if (empty($items)) {
Common::printDebug("There are no Ecommerce items in the request");
@@ -369,13 +369,13 @@ class GoalManager
return array();
}
- $items = Common::json_decode($items, $assoc = true);
-
if (!is_array($items)) {
Common::printDebug("Error while json_decode the Ecommerce items = " . var_export($items, true));
return false;
}
+ $items = Common::unsanitizeInputValues($items);
+
$cleanedItems = $this->getCleanedEcommerceItems($items);
return $cleanedItems;
}