diff options
author | Thomas Steur <tsteur@users.noreply.github.com> | 2018-12-04 08:56:24 +0300 |
---|---|---|
committer | diosmosis <diosmosis@users.noreply.github.com> | 2018-12-04 08:56:24 +0300 |
commit | 70505b1ebb5584a8a859bcb9a54e0cb50d66677e (patch) | |
tree | d93cb744b8e6f686625fda5f8c2ad26ca00bf56d /plugins/CorePluginsAdmin | |
parent | 332f42c8798685d1a7df425ebfa42b35937b9b5f (diff) |
Prevent trigger errors on demand for instances that are opened to anonymous (#13535)
fix #13513
Diffstat (limited to 'plugins/CorePluginsAdmin')
-rw-r--r-- | plugins/CorePluginsAdmin/Controller.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/CorePluginsAdmin/Controller.php b/plugins/CorePluginsAdmin/Controller.php index c8678e42f7..ba0cee89ff 100644 --- a/plugins/CorePluginsAdmin/Controller.php +++ b/plugins/CorePluginsAdmin/Controller.php @@ -348,12 +348,14 @@ class Controller extends Plugin\ControllerAdmin $this->tryToRepairPiwik(); - if (empty($lastError)) { + if (empty($lastError) && defined('PIWIK_TEST_MODE') && PIWIK_TEST_MODE) { $lastError = array( 'message' => Common::getRequestVar('error_message', null, 'string'), 'file' => Common::getRequestVar('error_file', null, 'string'), 'line' => Common::getRequestVar('error_line', null, 'integer') ); + } elseif (empty($lastError)) { + throw new Exception('Safemode not available'); } $outputFormat = Common::getRequestVar('format', 'html', 'string'); |