You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tabling this issue for now due to the complexity of fixing issues with specific types of options we use in most of our plugins; namely, checkbox values. Most of our plugins don't apply formatting filters to retrieved option values (except when retrieved by internal methods only accessible at the per-plugin level), so, because WordPress saves those option values as strings (e.g. '1' instead of true), comparing empty strings and checkbox values becomes much more complex.
Additionally, because we have logic in many of our plugins that incorrectly displays checkbox fields in plugin option pages based on whether their value is a boolean true (example: https://github.com/UCF/UCF-Degree-Search-Plugin/blob/master/admin/ucf-degree-search-config.php#L390), even if we did implement conditional update_option()'s, the checkbox option values wouldn't be rendered accurately if those checkboxes have a default "checked" value and the value is changed on save (unless the plugin has returned option filters set up), because '1' !== true.
Going to leave the update-option branch open until we can address the problem further.
TL;DR: this problem will require more extensive updates to the rest of our plugins before we can reliably and accurately make these option updates conditional.
Update all explicit
update_option()
calls in the theme withoption_${option_name}
filter hooks to eliminate unneeded db updates.The text was updated successfully, but these errors were encountered: