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:
authormattab <matthieu.aubry@gmail.com>2014-03-26 12:54:44 +0400
committermattab <matthieu.aubry@gmail.com>2014-03-26 12:54:44 +0400
commit5809c35541d8c7245563c14dd0f42fa0b98702ea (patch)
tree12a29d0df440781a6b8cef16d84e0f4ac8e648f0
parent1c70bfffb5d1f8834145798829f75060b0819636 (diff)
Refs #4909 Only update the visitEcommerceStatus flag if it's not NONE.
This will prevent some occurrences of this bug, but not the case where visitEcommerceStatus == abandonedCart
-rw-r--r--core/Tracker/Visit.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/core/Tracker/Visit.php b/core/Tracker/Visit.php
index b153dccb2f..ca35af28ed 100644
--- a/core/Tracker/Visit.php
+++ b/core/Tracker/Visit.php
@@ -942,7 +942,11 @@ class Visit implements VisitInterface
}
// Ecommerce buyer status
- $valuesToUpdate['visit_goal_buyer'] = $this->goalManager->getBuyerType($this->visitorInfo['visit_goal_buyer']);
+ $visitEcommerceStatus = $this->goalManager->getBuyerType($this->visitorInfo['visit_goal_buyer']);
+
+ if($visitEcommerceStatus != GoalManager::TYPE_BUYER_NONE) {
+ $valuesToUpdate['visit_goal_buyer'] = $visitEcommerceStatus;
+ }
// Custom Variables overwrite previous values on each page view
$valuesToUpdate = array_merge($valuesToUpdate, $this->visitorCustomVariables);