WordPress.org

Make WordPress Core

Opened 6 months ago

Last modified 2 months ago

#44669 assigned defect (bug)

Privacy Notification doesn't clear after dismissing notification

Reported by: ahortin Owned by: garrett-eclipse
Milestone: Future Release Priority: normal
Severity: normal Version: 4.9.7
Component: Privacy Keywords: needs-patch
Focuses: Cc:

Description

Every time the 'Suggested privacy policy text' is changed, the Settings > Privacy page displays a notification. Clicking the Close (x) icon doesn't clear the notification. If I navigate away from the page, the Privacy Policy notification reappears. The only way to clear the notification is to click the review the guide link.

If a site has a custom privacy policy page, like most typical business sites, then they shouldn't be forced to view this page every time it changes as it's not going to be relevant to them. The Close icon should clear the notification in the same way that clicking the review the guide link does.

Screenshot: https://cl.ly/3r0Y3m0P452X

Attachments (1)

privacy_notification.png (120.9 KB) - added by birgire 4 months ago.
Attached the screenshot, just in case the external screenshot link goes down.

Download all attachments as: .zip

Change History (15)

#1 @SergeyBiryukov
6 months ago

  • Milestone changed from Awaiting Review to 4.9.9

#2 @desrosj
6 months ago

  • Keywords needs-patch added

This ticket was mentioned in Slack in #core-privacy by desrosj. View the logs.


6 months ago

#4 follow-up: @norcross
6 months ago

I believe the UI has changed a bit, but the same issue is presented on the post editor itself. I'm happy to write the patch, but curious if anyone has a preferred approach (ajax call + option setting?)

example: https://www.dropbox.com/s/vfoqd6snlw7iprs/privacy-guide-notice.png?dl=0

#5 @idea15
5 months ago

  • Owner set to javorszky
  • Status changed from new to assigned

This ticket was mentioned in Slack in #core-privacy by desrosj. View the logs.


4 months ago

@birgire
4 months ago

Attached the screenshot, just in case the external screenshot link goes down.

#7 in reply to: ↑ 4 @garrett-eclipse
4 months ago

Replying to norcross:

I believe the UI has changed a bit, but the same issue is presented on the post editor itself. I'm happy to write the patch, but curious if anyone has a preferred approach (ajax call + option setting?)

example: https://www.dropbox.com/s/vfoqd6snlw7iprs/privacy-guide-notice.png?dl=0

Thanks @norcross, patches are always appreciated

The example you provided is a unique notice from the one discussed in this ticket so I've created a unique one for your concern. I'd love your thoughts and input there. Ticket - #44981

#8 @garrett-eclipse
4 months ago

As to the behaviour of the notice on the Privacy Settings page this ticket discusses I wonder if this would make more sense as custom code or plugin land as disabling the notice completely is a single line;

<?php
remove_action( 'admin_notices', array( 'WP_Privacy_Policy_Content', 'policy_text_changed_notice' ) );

For the basic user who hasn't gotten their policy created professionally the nag is a helpful prompt to understand their Privacy coverage has changed.

That aside if it's deemed this moves forward an AJAX call would have to be added on a $document.on( 'click', '.policy-text-updated.is-dismissable .notice-dismiss'... to force the update of _wp_suggested_privacy_policy_content post meta content so as to make $new == $old as this is how the text_change_check is handled;
https://github.com/WordPress/WordPress/blob/f7ba175491b725a5f3d636072c8b432774d38ae3/wp-admin/includes/misc.php#L1345-L1417

#9 @garrett-eclipse
4 months ago

I was going to propose the Dismiss Privacy Nag plugin - https://wordpress.org/plugins/dismiss-privacy-nag/
But that is for the pointer and doesn't cover this specific case

#10 @pento
4 months ago

  • Milestone changed from 4.9.9 to Future Release

This ticket was mentioned in Slack in #core-privacy by webdevlaw. View the logs.


4 months ago

#12 @desrosj
2 months ago

  • Owner javorszky deleted

This ticket was mentioned in Slack in #core-privacy by desrosj. View the logs.


2 months ago

#14 @garrett-eclipse
2 months ago

  • Owner set to garrett-eclipse
Note: See TracTickets for help on using tickets.