diff options
author | Thomas Steur <thomas.steur@googlemail.com> | 2014-04-03 05:40:24 +0400 |
---|---|---|
committer | Thomas Steur <thomas.steur@googlemail.com> | 2014-04-03 05:40:24 +0400 |
commit | 26d67856959d73946e54de76116c7169b1a3dd5f (patch) | |
tree | 5bf9112ab29a0d9d7921ec5c1c62b13498899564 /core/Tracker/Request.php | |
parent | c2c5e16ef232049061e1353dad20337395a86a9e (diff) |
the tracker should not define any limitations of the custom variables
Diffstat (limited to 'core/Tracker/Request.php')
-rw-r--r-- | core/Tracker/Request.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/core/Tracker/Request.php b/core/Tracker/Request.php index 3dbe3f98d8..80eb062733 100644 --- a/core/Tracker/Request.php +++ b/core/Tracker/Request.php @@ -16,6 +16,7 @@ use Piwik\IP; use Piwik\Piwik; use Piwik\Registry; use Piwik\Tracker; +use Piwik\Plugins\CustomVariables\Model as CustomVariablesModel; /** * The Request object holding the http parameters for this tracking request. Use getParam() to fetch a named parameter. @@ -355,7 +356,7 @@ class Request foreach ($customVar as $id => $keyValue) { $id = (int)$id; if ($id < 1 - || $id > Tracker::MAX_CUSTOM_VARIABLES + || $id > CustomVariablesModel::getMaxCustomVariables() || count($keyValue) != 2 || (!is_string($keyValue[0]) && !is_numeric($keyValue[0])) ) { @@ -379,7 +380,7 @@ class Request public static function truncateCustomVariable($input) { - return substr(trim($input), 0, Tracker::MAX_LENGTH_CUSTOM_VARIABLE); + return substr(trim($input), 0, CustomVariablesModel::getMaxLengthCustomVariables()); } protected function shouldUseThirdPartyCookie() |