Hi, I'm getting a warning on the WP Plug-In page that says: " Invalid argument supplied for foreach() in /home/scrunner/www/www/wp-content/themes/Divi/core/components/Updates.php on line 753
Screenshot of affected line is attached, does anyone see the issue?
Thanks!
Please check the error message: /themes/Divi/
It is your theme where the problem comes from.
Best regards, Michael
Thanks. I thought that I posted the code from that theme file. Here's the code below, there is an invalid argument on the line with the "foreach" statement. Anything obvious?
if ( false === $et_updated_plugins_data || ( $has_last_checked && $update_transient->last_checked !== $et_updated_plugins_data->last_checked ) ) {
$et_updated_plugins_data = new stdClass();
if ( ! empty( $update_transient->last_checked ) ) {
$et_updated_plugins_data->last_checked = $update_transient->last_checked;
}
foreach ( $update_transient->response as $response_plugin_settings ) {
$slug = sanitize_text_field( $response_plugin_settings->slug );
$et_updated_plugins_data->changelogs[ $slug ] = esc_url_raw( $response_plugin_settings->url . '?TB_iframe=true&width=1024&height=800' );
}
set_transient( 'et_updated_plugins_data', $et_updated_plugins_data );
}
You should post this to the theme forum. This is the wrong forum!