Skip to content

[PCP] Phase 2: WordPress.WP.DeprecatedFunctions#237

Open
faisalahammad wants to merge 1 commit into
WordPress:trunkfrom
faisalahammad:fix/pcp-phase-2-deprecated-functions
Open

[PCP] Phase 2: WordPress.WP.DeprecatedFunctions#237
faisalahammad wants to merge 1 commit into
WordPress:trunkfrom
faisalahammad:fix/pcp-phase-2-deprecated-functions

Conversation

@faisalahammad

@faisalahammad faisalahammad commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Fix: WordPress.WP.DeprecatedFunctions.add_option_whitelistFound (line 380)

Changes

  • Line 380: Add // phpcs:ignore WordPress.WP.DeprecatedFunctions annotation to add_option_whitelist() call, explaining this is an intentional WP 4.9 fallback — only invoked when add_allowed_options() doesn't exist

Rule code

WordPress.WP.DeprecatedFunctions.add_option_whitelistFound

Verification

  • PHPCS scan with WordPress standard shows zero violations for DeprecatedFunctions

Add phpcs:ignore comment explaining this is the intentional WP 4.9 fallback.
add_option_whitelist() is only called when add_allowed_options() doesn't exist.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant