Make WordPress Core

Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#31048 closed defect (bug) (fixed)

Missing PHPDoc $content param text in shortcode.php

Reported by: cais's profile cais Owned by: drewapicture's profile DrewAPicture
Milestone: 4.2 Priority: normal
Severity: normal Version: 3.6
Component: Shortcodes Keywords:
Focuses: docs Cc:

Description

There appears to be no PHPDoc param text for the $content variable being passed to has_shortcode(). The attached patch uses the same text for $content as used in do_shortcode().

Attachments (2)

31048.patch (473 bytes) - added by cais 10 years ago.
31048.2.patch (1.2 KB) - added by SergeyBiryukov 10 years ago.

Download all attachments as: .zip

Change History (8)

@cais
10 years ago

#1 follow-up: @DrewAPicture
10 years ago

  • Milestone changed from Awaiting Review to 4.2

Hi cais, thanks for the patch.

I think if we're in there adding a missing parameter and description, we should probably also cover the description for $tag and the return value. Would you care to include those in your patch?

#2 @SergeyBiryukov
10 years ago

Noticed some other inconsistencies, see 31048.2.patch.

Last edited 10 years ago by SergeyBiryukov (previous) (diff)

#3 in reply to: ↑ 1 @cais
10 years ago

Replying to DrewAPicture:

Hi cais, thanks for the patch.

I think if we're in there adding a missing parameter and description, we should probably also cover the description for $tag and the return value. Would you care to include those in your patch?

... looks like I wasn't quick enough. Sergey appears to have covered those.

#4 @DrewAPicture
10 years ago

In 31242:

Ensure both parameters and the return for has_shortcode() are fully documented.

Props cais, SergeyBiryukov
See #31048.

#5 @DrewAPicture
10 years ago

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

In 31243:

Add more complete documentation for parameters, globals, and return values to the DocBlocks for remove_shortcode(), shortcode_exists(), and do_shortcode().

Props SergeyBiryukov.
Fixes #31048.

#6 @DrewAPicture
10 years ago

In 31245:

Remove a stray period introduced in [31242].

Props SergeyBiryukov.
See #31048.

Note: See TracTickets for help on using tickets.