[wp-trac] [WordPress Trac] #60328: Deprecated parameter default value of unregister_setting() is not correct type
WordPress Trac
noreply at wordpress.org
Sat Jan 27 11:25:21 UTC 2024
#60328: Deprecated parameter default value of unregister_setting() is not correct
type
-------------------------------------------------+-------------------------
Reporter: crstauf | Owner: audrasjb
Type: defect (bug) | Status: reviewing
Priority: normal | Milestone: Awaiting
| Review
Component: General | Version:
Severity: normal | Resolution:
Keywords: has-patch changes-requested needs- | Focuses: docs
unit-tests |
-------------------------------------------------+-------------------------
Comment (by gerardreches):
Replying to [comment:3 audrasjb]:
> Hi there, thanks for the patch.
> @crstauf @gerardreches the pull request triggers some PHPUnit issues.
> I think the condition `if ( '' !== $deprecated ) ` needs to be updated
to check for `null`. The related PHPUnit tests should probably be updated,
too.
I think that for backward compatibility we should keep that condition, and
then add an additional one for null:
if ( '' !== $deprecated && null !== $deprecated ) {
on line 2836 in option.php
--
Ticket URL: <https://core.trac.wordpress.org/ticket/60328#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list