Make WordPress Core

Opened 13 years ago

Closed 12 years ago

#26979 closed defect (bug) (fixed)

Hook Docs (6): wp-includes/revision.php

Reported by: adamsilverstein Owned by: DrewAPicture
Priority: normal Milestone: 3.9
Component: Revisions Version:
Severity: normal Keywords: has-patch commit
Cc: Focuses: docs

Description

Lets add some docs for the hooks in wp-includes/revision.php!

Attachments (3)

26979.diff (2.4 KB ) - added by adamsilverstein 13 years ago.
26979.2.diff (2.7 KB ) - added by adamsilverstein 12 years ago.
docs corrections, cleanup
26979.3.diff (4.5 KB ) - added by DrewAPicture 12 years ago.
Final pass.

Download all attachments as: .zip

Change History (11)

#1 @kpdesign
13 years ago

  • Keywords needs-patch added
  • Summary Hook Docs for wp-includes/revision.phpHook Docs (6): wp-includes/revision.php
  • Type enhancementdefect (bug)

#2 @DrewAPicture
13 years ago

  • Keywords has-patch added; needs-patch removed

#3 @DrewAPicture
13 years ago

  • Owner set to DrewAPicture
  • Status newreviewing

Thanks for the patch. I'll work up some notes and get back to you.

This ticket was mentioned in IRC in #wordpress-dev by adamsilverstein. View the logs.


12 years ago

#5 follow-up: @DrewAPicture
12 years ago

  • Component GeneralRevisions
  • Keywords needs-patch added; has-patch removed
  • Version trunk

Here are some notes on 26979.diff:

_wp_post_revision_fields filter:

  • Don't need the hash notation here since it's really just an array of translatable strings. You can just say:

@param array $fields List of fields to revision. Contains 'post_title', 'post_content', and 'post_excerpt' by default.

  • Should only be one space between the @since tag and version

wp_save_post_revision_check_for_changes filter:

  • Need a docs-specific variable for the first parameter. Maybe $changes.
  • s/id/ID in two places

With the above changes should be able to get this in shortly.

@adamsilverstein
12 years ago

docs corrections, cleanup

#6 in reply to: ↑ 5 @adamsilverstein
12 years ago

  • Keywords has-patch dev-feedback added; needs-patch removed

Thanks for the review and feedback; I have (hopefully) addressed all these issues in 26979.2.diff.

Replying to DrewAPicture:

Here are some notes on 26979.diff:

_wp_post_revision_fields filter:

  • Don't need the hash notation here since it's really just an array of translatable strings. You can just say:

@param array $fields List of fields to revision. Contains 'post_title', 'post_content', and 'post_excerpt' by default.

  • Should only be one space between the @since tag and version

wp_save_post_revision_check_for_changes filter:

  • Need a docs-specific variable for the first parameter. Maybe $changes.
  • s/id/ID in two places

With the above changes should be able to get this in shortly.

@DrewAPicture
12 years ago

Final pass.

#7 @DrewAPicture
12 years ago

  • Keywords commit added; dev-feedback removed
  • Milestone Awaiting Review3.9

26979.3.diff cleans up some of the wording on the filters in .2 and adds hook docs for all of the actions. Good to go.

#8 @DrewAPicture
12 years ago

  • Resolutionfixed
  • Status reviewingclosed

In 27699:

Inline documentation for hooks in wp-includes/revision.php.

Props adamsilverstein, DrewAPicture.
Fixes #26979.

Note: See TracTickets for help on using tickets.