WordPress.org

Make WordPress Core

Opened 3 months ago

Closed 3 months ago

Last modified 3 months ago

#49802 closed defect (bug) (fixed)

Move wp_get_user_request_data deprecation to wp-includes/deprecated.php for front-end back-compat

Reported by: garrett-eclipse Owned by: SergeyBiryukov
Milestone: 5.4.1 Priority: normal
Severity: normal Version: 5.4
Component: Privacy Keywords: has-patch commit early fixed-major
Focuses: Cc:

Description

As pointed out by @johnjamesjacoby in his comment;

I believe this was erroneously deprecated into:

/wp-admin/includes/deprecated.php

instead of:

/wp-includes/deprecated.php.

Both the original function and the new one are available outside of WordPress admin, but the deprecated function is now only available within WordPress admin, which is a back-compat break.

See: https://buddypress.trac.wordpress.org/ticket/8265

@SergeyBiryukov Reopen, or create a new issue for 5.4.1?

This is a correct assessment and should be addressed in 5.4.1

Attachments (1)

49802.diff (1.6 KB) - added by garrett-eclipse 3 months ago.
Migrate the wp_get_user_request_data deprecation from wp-admin/includes/deprecated.php to wp-includes/deprecated.php

Download all attachments as: .zip

Change History (7)

@garrett-eclipse
3 months ago

Migrate the wp_get_user_request_data deprecation from wp-admin/includes/deprecated.php to wp-includes/deprecated.php

#1 @garrett-eclipse
3 months ago

  • Keywords has-patch needs-testing added

In 49802.diff I've migrated the deprecated code to enable it for access outside of the admin. For the PHPDOC I left it as deprecated in 5.4.0 but was wondering if I should somehow flag in 5.4.1 this is migrated to a new location.
Please prop @johnjamesjacoby as the original reporter.

#2 @johnjamesjacoby
3 months ago

  • Keywords commit early added; needs-testing removed

Patch fixes the regression.

Also tested with BuddyPress specifically, which no longer fatal errors with this patch applied.

Removing the "needs-testing" keyword, and adding "commit" & "early".

The 5.4.1 release lead can prioritize as they see it fitting into this release. (Also happy to commit myself once it's OK to.)

#3 @SergeyBiryukov
3 months ago

  • Owner set to SergeyBiryukov
  • Resolution set to fixed
  • Status changed from new to closed

In 47555:

Privacy: Make the deprecated wp_get_user_request_data() function available on front end.

Previously, it was accidentally made available only in admin context.

Follow-up to [44606], [47245].

Props garrett-eclipse, johnjamesjacoby, r-a-y, Dono12.
Fixes #49802.

#4 @SergeyBiryukov
3 months ago

  • Keywords fixed-major added
  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening for 5.4.1.

#5 @whyisjake
3 months ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In 47567:

Privacy: Make the deprecated wp_get_user_request_data() function available on front end.

Previously, it was accidentally made available only in admin context.

Follow-up to [44606], [47245].
Brings [47555] to the 5.4 branch.

Props garrett-eclipse, johnjamesjacoby, r-a-y, Dono12.

Fixes #49802.

This ticket was mentioned in Slack in #core by imath. View the logs.


3 months ago

Note: See TracTickets for help on using tickets.