WordPress.org

Make WordPress Core

Opened 11 months ago

Closed 11 months ago

Last modified 11 months ago

#48335 closed defect (bug) (invalid)

Yoda condition missing class-wp-rest-request.php line 337

Reported by: 1naveengiri Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: REST API Keywords:
Focuses: rest-api, coding-standards Cc:

Description

Check the attached screenshot.

In class-wp-rest-request.php at line #337, the line should be


if ( 'application/json' === $content_type['value'] ) 

Attachments (1)

Screenshot.jpg (34.5 KB) - added by 1naveengiri 11 months ago.

Download all attachments as: .zip

Change History (6)

#2 @mukesh27
11 months ago

  • Keywords reporter-feedback added

Thanks for reporting this, @1naveengiri! I can't replicate the same issue in WordPress version 5.3-RC1-46560 and in GitHub repo https://github.com/WordPress/WordPress/blob/master/wp-includes/rest-api/class-wp-rest-request.php#L339 I can't found the same issue.

Can you please check it

#3 @1naveengiri
11 months ago

  • Resolution set to invalid
  • Status changed from new to closed

Awesome, its seems fixed in WP 5.3-RC1-46560.
Thanks for checking it @mukesh27

I will close it. seems no need of it now.

#4 @ocean90
11 months ago

  • Keywords needs-patch reporter-feedback removed
  • Milestone Awaiting Review deleted
  • Version trunk deleted

#5 @garrett-eclipse
11 months ago

For reference, this was fixed in #47704

Note: See TracTickets for help on using tickets.