[wp-trac] [WordPress Trac] #35379: update_network_option changes stored option value if sanitize_option detects error
WordPress Trac
noreply at wordpress.org
Mon Jan 18 23:46:55 UTC 2016
#35379: update_network_option changes stored option value if sanitize_option
detects error
------------------------------------------+------------------------
Reporter: thomaswm | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.5
Component: Options, Meta APIs | Version: 3.0
Severity: normal | Resolution:
Keywords: needs-patch needs-unit-tests | Focuses: multisite
------------------------------------------+------------------------
Changes (by jeremyfelt):
* keywords: => needs-patch needs-unit-tests
* version: 4.4 => 3.0
* milestone: Awaiting Review => 4.5
Comment:
Confirmed.
It looks like this was introduced in [14231] not too long after
`update_site_option()` was made multisite aware. It originally affected
`admin_email` and `siteurl`. In [18346], `WPLANG` got similar treatment.
And as of [32791], some of the fallback logic was consolidated and it now
appears to affect `illegal_names` as well. This applies to several other
single site options, but not all of them share names with network options.
I guess our two options are to add a `sanitize_network_option()` or add
context to `sanitize_option()`. I'm inclined to go the route of
`sanitize_network_option()` so that we can also account for the other
network options that do not match the names of site options.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/35379#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list