Make WordPress Core

Opened 10 years ago

Closed 10 years ago

#25526 closed defect (bug) (fixed)

Deprecate format_to_post

Reported by: simonwheatley's profile simonwheatley Owned by: johnbillion's profile johnbillion
Milestone: 3.9 Priority: normal
Severity: normal Version: 1.2
Component: Formatting Keywords: has-patch dev-feedback
Focuses: Cc:

Description

While documenting the hooks in formatting.php (#25518) I noticed format_to_post which is unused except for 25 or so plugins in the repo. The description is generic, and useless.

WAY back in the day it seems it was used to add slashes before stuff got put into the database.

After asking around, I think we should deprecate it.

Attachments (1)

25526.diff (1.7 KB) - added by simonwheatley 10 years ago.
Deprecates formt_to_post. Adds docs for hook within deprecated function.

Download all attachments as: .zip

Change History (8)

#1 @simonwheatley
10 years ago

(I checked, and format_to_post is not used in core.)

#2 @simonwheatley
10 years ago

  • Component changed from General to Formatting
  • Version set to 1.2

#3 @simonwheatley
10 years ago

Can't set the version low enough, should be 0.71, so went as low as I could. :)

@simonwheatley
10 years ago

Deprecates formt_to_post. Adds docs for hook within deprecated function.

#4 @simonwheatley
10 years ago

Added docs for hook within deprecated function. Add alternative suggestion.

#5 @SergeyBiryukov
10 years ago

  • Keywords 3.9-early added
  • Milestone changed from Awaiting Review to Future Release

#6 @nacin
10 years ago

  • Keywords 3.9-early removed
  • Milestone changed from Future Release to 3.9

I think it's safe to just kill the hook while we're at it. (Or not bother documenting it?)

I found the function definition from a ways back. Here's it being changed at one point: [1021]. Scary stuff, right there.

#7 @johnbillion
10 years ago

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

In 27424:

Deprecate format_to_post() and remove its filter. Fixes #25526. Props simonwheatley

Note: See TracTickets for help on using tickets.