Repository navigation
Conversation
The whitelist_options filter was deprecated in WordPress 5.5 in favor of allowed_options, so the snippet logged a deprecation notice when WP_DEBUG was on. Also add the opening PHP tag and a plugin header so the block works as a plugin file, and note the filter's name before 5.5.
mindctrl
approved these changes
Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #535.
The Multisite snippet on Update Services adds
ping_sitesto the allowed options with thewhitelist_optionsfilter, which Core deprecated in WordPress 5.5. The page also offers the snippet as a custom plugin or must-use plugin, but the code block had no opening<?phptag or plugin header, so it did not work as a plugin file as written.This:
allowed_optionsand changes the "Whitelist" comment to "Allow";<?phpand aPlugin Nameheader, so the block works as a must-use plugin or as a regular plugin;allowed_optionsfilter added in WordPress 5.5, and that older versions should usewhitelist_optionsinstead.Testing
In Docker, on a Multisite network (subdirectory install) with
WP_DEBUGandWP_DEBUG_LOGon, the network admin saved Settings > Writing with a new Update Services URL. The tested file is the page's code block, byte for byte.WordPress 7.1.3 (PHP 8.3):
ping_sitesunchanged.whitelist_options), must-use plugin: the URL is saved, anddebug.loggets "Hook whitelist_options is deprecated since version 5.5.0! Use allowed_options instead."WordPress 5.4.2 (PHP 7.4):
Use of AI Tools
AI assistance: Yes
Tool(s): Claude Code and Codex
Used for: Finding the issue by checking the handbook's hook names against Core, the change, Docker testing, and the wording of this description. I reviewed the change and the results, and I take responsibility for the contribution.