[wp-trac] [WordPress Trac] #62950: PHP deprecation warning in /wp-admin/includes/class-automatic-upgrader-skin.php
WordPress Trac
noreply at wordpress.org
Fri Mar 20 21:38:30 UTC 2026
#62950: PHP deprecation warning in /wp-admin/includes/class-automatic-upgrader-
skin.php
-----------------------------+------------------------------
Reporter: nexbridge | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Upgrade/Install | Version: 6.7.2
Severity: normal | Resolution:
Keywords: | Focuses:
-----------------------------+------------------------------
Comment (by sabernhardt):
Something else is setting a `null` value earlier. It runs through the
`update_feedback` filter before reaching
`Automatic_Upgrader_Skin::feedback()`. [https://wordpress.org/plugins
/stops-core-theme-and-plugin-updates/ Easy Updates Manager] lets **any**
non-string pass through its [https://plugins.trac.wordpress.org/browser
/stops-core-theme-and-plugin-
updates/trunk/includes/MPSUM_Logs.php?rev=3415201&marks=331#L325
set_core_update_notes] because the author(s) knew it could be a `WP_Error`
object.
However, `Automatic_Upgrader_Skin::feedback()` only supports `string`,
`array`, or `WP_Error`.
If merely silencing the error is acceptable, the conditions could be
rearranged:
{{{
if ( is_wp_error( $feedback ) ) {
$string = $feedback->get_error_message();
} elseif ( is_string( $feedback ) ) {
$string = $feedback;
} else {
// Return if $feedback is an array or an unsupported type.
return;
}
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/62950#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list