New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for Tracker INI settings to be set for each website #17636
Conversation
f3c45dd
to
ad37df6
Compare
core/Tracker/Response.php
Outdated
@@ -25,7 +25,7 @@ public function init(Tracker $tracker) | |||
{ | |||
ob_start(); // we use ob_start only because of Common::printDebug, we should actually not really use ob_start | |||
|
|||
if ($tracker->isDebugModeEnabled() && TrackerConfig::getConfigValue('enable_sql_profiler')) { | |||
if ($tracker->isDebugModeEnabled() && TrackerConfig::getConfigValue('enable_sql_profiler', $this->getIdSite())) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fyi @diosmosis this method getIdSite doesn't seem to be defined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we could just remove idSite
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 this one doesn't need to be overridden
@diosmosis added https://matomo.org/faq/how-to/how-do-i-configure-a-config-setting-in-the-config-ini-php-differently-for-a-specific-site/ and also added the logic for 3 more settings where this may be quite useful. Once tests pass it should be good to merge. |
@diosmosis a few tests seem to need fixing and then should be good to merge |
Description:
This change allows INI config sections like
[Tracker_$idSite]
to be added which will override some Tracker config for individual sites. Config that should be applied overall (or in places where we don't know what the idSite is), cannot be overridden.Review