Make WordPress Core

Opened 13 years ago

Closed 13 years ago

#25530 closed defect (bug) (fixed)

WP_Image_Editor: inline documentation fixed for multi_resize array keys

Reported by: paolal Owned by: DrewAPicture
Priority: normal Milestone: 3.7
Component: Inline Docs Version:
Severity: normal Keywords: has-patch commit
Cc: Focuses:

Description

Added mention that:

	 * The key of each array will be returned as the image size (generally 'small', 'medium', or 'large').

and updated example:

	 * @param array $sizes { ['size'] => {'width'=>int, 'height'=>int, ['crop'=>bool]}, ... }

to remind that even if the key is not required, it has to be returned by the function due to core's utilisation of multi_resize

Seen with @DH-Shredder

Attachments (2)

25530.diff (2.7 KB ) - added by paolal 13 years ago.
25530.2.diff (3.2 KB ) - added by DrewAPicture 13 years ago.
hash notations

Download all attachments as: .zip

Change History (7)

@paolal
13 years ago

#1 @markoheijnen
13 years ago

  • Keywords has-patch commit added
  • Milestone Awaiting Review3.7

looks great and ready to commit.

#2 @DrewAPicture
13 years ago

  • Keywords commit removed

Array parameters should be documented using the hash notation style outlined in the inline docs standards.

#3 @DrewAPicture
13 years ago

  • Keywords needs-patch added; has-patch removed

@DrewAPicture
13 years ago

hash notations

#4 @DrewAPicture
13 years ago

  • Keywords has-patch commit added; needs-patch removed

25530.2.diff handles the array hash notations.

#5 @DrewAPicture
13 years ago

  • Owner set to DrewAPicture
  • Resolutionfixed
  • Status newclosed

In 25728:

Improve inline documentation for the multi_resize() method in WP_Image_Editor, WP_Image_Editor_GD, and WP_Image_Editor_Imagick.

Props paolal for the initial patch.
Fixes #25530.

Note: See TracTickets for help on using tickets.