Make WordPress Core

#58481 closed defect (bug) (fixed)

Mark `apply_filters()` third parameter as optional

Reported by: audrasjb's profile audrasjb Owned by: audrasjb's profile audrasjb
Milestone: 6.3 Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch commit
Focuses: docs Cc:

Description

The $args parameter of apply_filters() is optional. We should update the related Docblock description accordingly so the parameter is not indicated as required on DevHub.

See https://developer.wordpress.org/reference/functions/apply_filters/

Props @gilles66 for pointing this out in a DevHub comment.

Attachments (2)

Capture d’écran 2023-06-06 à 17.12.01.png (97.8 KB) - added by audrasjb 20 months ago.
apply-filter-fix.diff (712 bytes) - added by gaeldenysiak 20 months ago.

Download all attachments as: .zip

Change History (6)

#1 @gaeldenysiak
20 months ago

Hi, my name is Gael. I've been working on WordPress for a while and I'm excited to offer my first contribution, which I hope will be the first of many :) Have a great day, community!

#2 @audrasjb
20 months ago

  • Focuses docs added
  • Milestone changed from Awaiting Review to 6.3

#3 @audrasjb
20 months ago

  • Keywords has-patch commit added

Hey @gaeldenysiak welcome to Trac and thanks for the patch!

Looks good to ship!

#4 @audrasjb
20 months ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 55893:

Docs: Mark apply_filters() third parameter $args as optional.

The $args parameter of apply_filters() is optional. This changeset updates the related Docblock description accordingly so the parameter is not marked as
required on DevHub.

Props gaeldenysiak, audrasjb, gilles66.
Fixes #58481.
See #57840.

Note: See TracTickets for help on using tickets.