WordPress.org

Make WordPress Core

Opened 14 months ago

Closed 8 months ago

Last modified 8 months ago

#23680 closed enhancement (fixed)

Obsolete function previously used in Theme Editor

Reported by: SergeyBiryukov Owned by: SergeyBiryukov
Milestone: 3.7 Priority: normal
Severity: normal Version: 2.9
Component: Administration Keywords:
Focuses: Cc:

Description

get_real_file_to_edit() is unused since [12063] and should probably be deprecated:
http://core.trac.wordpress.org/browser/tags/3.5.1/wp-admin/includes/file.php#L96

Attachments (2)

23680.diff (731 bytes) - added by iamfriendly 8 months ago.
23680-2.diff (2.3 KB) - added by iamfriendly 8 months ago.

Download all attachments as: .zip

Change History (9)

comment:1 SergeyBiryukov8 months ago

  • Milestone changed from Awaiting Review to 3.7
  • Version set to 2.9

iamfriendly8 months ago

comment:2 iamfriendly8 months ago

Added a patch to place the _deprecated_function() call as well as updated the docblock to indicate the function has been deprecated, too.

comment:3 iamfriendly8 months ago

  • Cc richard@… added

comment:4 nacin8 months ago

We should move this function to wp-admin/includes/deprecated.php. We should also remove the first part of the function that supports .htaccess and the root index.php file, and instead just return WP_CONTENT_DIR . $arg;

comment:5 iamfriendly8 months ago

Moving it makes absolute sense, I should have done that in the first place. Also just returning WP_CONTENT_DIR . $arg makes sense too, I just didn't want to amend the function too much. New Patch Added :)

iamfriendly8 months ago

comment:6 SergeyBiryukov8 months ago

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

In 25201:

Move get_real_file_to_edit() to wp-admin/includes/deprecated.php. props iamfriendly. fixes #23680.

comment:7 SergeyBiryukov8 months ago

In 25208:

Move get_real_file_to_edit() upper in the file for consistency with the existing order of functions. Some phpdoc fixes and additions. see #23680.

Note: See TracTickets for help on using tickets.