WordPress.org

Make WordPress Core

Opened 5 weeks ago

Closed 5 weeks ago

#54389 closed enhancement (fixed)

Rename class-http.php to class-wp-http.php

Reported by: SergeyBiryukov Owned by: SergeyBiryukov
Milestone: 5.9 Priority: normal
Severity: normal Version:
Component: HTTP API Keywords:
Focuses: coding-standards Cc:

Description

Background: #33413, #34432, #36335, #36618, #47632, #47775.

This follows up on the work that started in #33413 and continued in the subsequent tickets to make sure WP core PHP classes are located in separate files and conform to the naming conventions per WordPress coding standards:

  • [45654] renamed wp-admin/custom-header.php to wp-admin/includes/class-custom-image-header.php.
  • [45662] renamed wp-admin/custom-background.php to wp-admin/includes/class-custom-background.php.
  • [45663] renamed wp-includes/class-oembed.php to wp-includes/class-wp-oembed.php.
  • [45678] renamed wp-includes/date.php to wp-includes/class-wp-date-query.php.

See comment:33:ticket:47632 for a general procedure with these renamings.

The same should be done for the WP_Http class, which currently resides in wp-includes/class-http.php and should be moved to wp-includes/class-wp-http.php.

Change History (1)

#1 @SergeyBiryukov
5 weeks ago

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

In 52026:

Coding Standards: Move wp-includes/class-http.php to wp-includes/class-wp-http.php.

This renames the file containing the WP_Http class to conform to the coding standards.

This commit also includes:

  • A new class-http.php that includes the new file, for anyone that may've been including the file directly.
  • Replaces references to the old filename with the new filename.

Follow-up to [8516], [13274], [33748].

Fixes #54389. See #53359.

Note: See TracTickets for help on using tickets.