diff options
author | Thomas Steur <thomas.steur@googlemail.com> | 2014-11-14 03:27:42 +0300 |
---|---|---|
committer | Thomas Steur <thomas.steur@googlemail.com> | 2014-11-14 03:27:42 +0300 |
commit | 332af2a3085cf3b35815d1f4b55f9059a627819a (patch) | |
tree | 7c408b2c359b15f8805e7b92a8ec97e26ee68be7 /core | |
parent | e66c3d52a9e9564374d65732d19a2cec5d65bf2e (diff) |
refs #6661 forgot to commit a file and if not suppported param is used is actually a server error not request error
Diffstat (limited to 'core')
-rw-r--r-- | core/Tracker.php | 4 | ||||
-rw-r--r-- | core/Tracker/Request.php | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/core/Tracker.php b/core/Tracker.php index 9d7af54c36..faef4ea14b 100644 --- a/core/Tracker.php +++ b/core/Tracker.php @@ -9,6 +9,7 @@ namespace Piwik; use Exception; +use Piwik\Exception\InvalidRequestParameterException; use Piwik\Exception\UnexpectedWebsiteFoundException; use Piwik\Plugins\PrivacyManager\Config as PrivacyManagerConfig; use Piwik\Plugins\SitesManager\SiteUrls; @@ -848,6 +849,9 @@ class Tracker } catch (UnexpectedWebsiteFoundException $e) { Common::printDebug("Exception: " . $e->getMessage()); $this->exitWithException($e, $isAuthenticated, 400); + } catch (InvalidRequestParameterException $e) { + Common::printDebug("Exception: " . $e->getMessage()); + $this->exitWithException($e, $isAuthenticated, 400); } catch (DbException $e) { Common::printDebug("Exception: " . $e->getMessage()); $this->exitWithException($e, $isAuthenticated); diff --git a/core/Tracker/Request.php b/core/Tracker/Request.php index efc3f331d9..bc70513216 100644 --- a/core/Tracker/Request.php +++ b/core/Tracker/Request.php @@ -306,7 +306,7 @@ class Request ); if (!isset($supportedParams[$name])) { - throw new InvalidRequestParameterException("Requested parameter $name is not a known Tracking API Parameter."); + throw new Exception("Requested parameter $name is not a known Tracking API Parameter."); } $paramDefaultValue = $supportedParams[$name][0]; |