PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 16.3-a.1
Jetpack – WP Security, Backup, Speed, & Growth v16.3-a.1
16.3-a.3 16.3-a.1 16.2 16.2-beta 12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 13.8.3 13.9.2 14.0.1 All 504 releases
← All changes | _inc/lib/class-jetpack-recommendations.php +2 -2 13.7.216.3-a.1 View file →
@@ -170,9 +170,9 @@
170 170 'woocommerce.php',
171 171 );
172 172
173 173 $path_parts = explode( '/', $plugin );
174 - $plugin_file = $path_parts ? array_pop( $path_parts ) : $plugin;
174 + $plugin_file = array_pop( $path_parts );
175 175
176 176 if ( ! in_array( $plugin_file, $plugin_whitelist, true ) ) {
177 177 $products = array_column( Jetpack_Plan::get_products(), 'product_slug' );
178 178
@@ -381,9 +381,9 @@
381 381 */
382 382 public static function get_new_conditional_recommendations() {
383 383 $conditional_recommendations = self::get_conditional_recommendations();
384 384 $recommendations_data = Jetpack_Options::get_option( 'recommendations_data', array() );
385 - $viewed_recommendations = isset( $recommendations_data['viewedRecommendations'] ) ? $recommendations_data['viewedRecommendations'] : array();
385 + $viewed_recommendations = $recommendations_data['viewedRecommendations'] ?? array();
386 386
387 387 // array_diff returns a keyed array - reduce to unique values.
388 388 return array_unique( array_values( array_diff( $conditional_recommendations, $viewed_recommendations ) ) );
389 389 }