-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Add event to update policy description to support cloud only links appearing #23723
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
base: 5.x-dev
Are you sure you want to change the base?
Conversation
| $description = Piwik::translate('General_ComplianceCNILDescription'); | ||
|
|
||
| $isCloud = false; | ||
|
|
||
| /** | ||
| * This event should only be used by the cloud plugin, to determine that the | ||
| * current instance is a cloud instance. | ||
| */ | ||
| Piwik::postEvent('Policy.onCloudInstance', [$isCloud]); | ||
|
|
||
| if ($isCloud) { | ||
| $description .= ' ' . Piwik::translate('General_ComplianceDPALink', ['<a href="https://matomo.org/matomo-cloud-dpa/">', '</a>']); | ||
| } | ||
|
|
||
| return $description; |
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.
As we don't want any cloud specific code in core, we should only post an event to update the description, and handle the rest in the cloud plugin.
Passing the policy class through the event as well if the event consumer wanted different updates per policy.
| $description = Piwik::translate('General_ComplianceCNILDescription'); | |
| $isCloud = false; | |
| /** | |
| * This event should only be used by the cloud plugin, to determine that the | |
| * current instance is a cloud instance. | |
| */ | |
| Piwik::postEvent('Policy.onCloudInstance', [$isCloud]); | |
| if ($isCloud) { | |
| $description .= ' ' . Piwik::translate('General_ComplianceDPALink', ['<a href="https://matomo.org/matomo-cloud-dpa/">', '</a>']); | |
| } | |
| return $description; | |
| $description = Piwik::translate('General_ComplianceCNILDescription'); | |
| Piwik::postEvent('CompliancePolicy.updateDescription', [&$description, self::class]); | |
| return $description; |
| "Comparisons": "Comparisons", | ||
| "ComplianceCNILTitle": "CNIL website analytics consent exemption conditions", | ||
| "ComplianceCNILDescription": "This table provides an indication of whether certain settings align with CNIL guidance. It does not guarantee full legal compliance. To qualify for the consent exemption under CNIL rules, all required configurations must be implemented. If any setting is shown as “Non-Compliant,” the exemption conditions are not met, and consent must be obtained from users. If any setting is shown as “Unknown” Matomo cannot determine whether this requirement has been implemented. In such cases, these measures must be manually verified.", | ||
| "ComplianceDPALink": "%1$sData Processing Agreement.%2$s", |
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 would live in the cloud plugin
| - | ||
| message: "#^If condition is always false\\.$#" | ||
| count: 1 | ||
| path: core/Policy/CnilPolicy.php | ||
|
|
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 would be gone as we remove the conditional logic and handle it in cloud plugin.
Description:
Please include a description of this change and which issue it fixes. If no issue exists yet please include context and what problem it solves.
Review