Skip to content

Commit 8ccdf72

Browse files
committed
Merge branch 'trunk' of github.com:Yoast/wordpress-seo into PC-865-exclude-links-from-prominent-words
2 parents f940c11 + f7d3b9a commit 8ccdf72

251 files changed

Lines changed: 4861 additions & 6352 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

admin/ajax.php

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -317,20 +317,3 @@ function wpseo_register_ajax_integrations() {
317317
new WPSEO_Shortcode_Filter();
318318

319319
new WPSEO_Taxonomy_Columns();
320-
321-
/* ********************* DEPRECATED FUNCTIONS ********************* */
322-
323-
/**
324-
* Hides the default tagline notice for a specific user.
325-
*
326-
* @deprecated 13.2
327-
* @codeCoverageIgnore
328-
*/
329-
function wpseo_dismiss_tagline_notice() {
330-
if ( ! current_user_can( 'manage_options' ) ) {
331-
die( '-1' );
332-
}
333-
334-
_deprecated_function( __FUNCTION__, 'WPSEO 13.2', 'This method is deprecated.' );
335-
wpseo_ajax_json_echo_die( '' );
336-
}

admin/class-admin-init.php

Lines changed: 11 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ public function __construct() {
3636

3737
add_action( 'admin_enqueue_scripts', [ $this, 'enqueue_dismissible' ] );
3838
add_action( 'admin_init', [ $this, 'unsupported_php_notice' ], 15 );
39+
add_action( 'admin_init', [ $this, 'remove_translations_notification' ], 15 );
3940
add_action( 'admin_init', [ $this->asset_manager, 'register_assets' ] );
4041
add_action( 'admin_init', [ $this, 'show_hook_deprecation_warnings' ] );
4142
add_action( 'admin_init', [ 'WPSEO_Plugin_Conflict', 'hook_check_for_plugin_conflicts' ] );
@@ -57,6 +58,16 @@ public function enqueue_dismissible() {
5758
$this->asset_manager->enqueue_style( 'dismissible' );
5859
}
5960

61+
/**
62+
* Removes any notification for incomplete translations.
63+
*
64+
* @return void
65+
*/
66+
public function remove_translations_notification() {
67+
$notification_center = Yoast_Notification_Center::get();
68+
$notification_center->remove_notification_by_id( 'i18nModuleTranslationAssistance' );
69+
}
70+
6071
/**
6172
* Creates an unsupported PHP version notification in the notification center.
6273
*
@@ -320,68 +331,4 @@ public function add_publish_box_section( $post ) {
320331
do_action( 'wpseo_publishbox_misc_actions', $post );
321332
}
322333
}
323-
324-
/* ********************* DEPRECATED METHODS ********************* */
325-
326-
/**
327-
* Notify about the default tagline if the user hasn't changed it.
328-
*
329-
* @deprecated 13.2
330-
* @codeCoverageIgnore
331-
*/
332-
public function tagline_notice() {
333-
_deprecated_function( __METHOD__, 'WPSEO 13.2' );
334-
}
335-
336-
/**
337-
* Returns whether or not the site has the default tagline.
338-
*
339-
* @deprecated 13.2
340-
* @codeCoverageIgnore
341-
*
342-
* @return bool
343-
*/
344-
public function has_default_tagline() {
345-
_deprecated_function( __METHOD__, 'WPSEO 13.2' );
346-
347-
$blog_description = get_bloginfo( 'description' );
348-
$default_blog_description = 'Just another WordPress site';
349-
350-
// We are using the WordPress internal translation.
351-
$translated_blog_description = __( 'Just another WordPress site', 'default' );
352-
353-
return $translated_blog_description === $blog_description || $default_blog_description === $blog_description;
354-
}
355-
356-
/**
357-
* Shows an alert when the permalink doesn't contain %postname%.
358-
*
359-
* @deprecated 13.2
360-
* @codeCoverageIgnore
361-
*/
362-
public function permalink_notice() {
363-
_deprecated_function( __METHOD__, 'WPSEO 13.2' );
364-
}
365-
366-
/**
367-
* Add an alert if the blog is not publicly visible.
368-
*
369-
* @deprecated 14.1
370-
* @codeCoverageIgnore
371-
*/
372-
public function blog_public_notice() {
373-
_deprecated_function( __METHOD__, 'WPSEO 14.1' );
374-
}
375-
376-
/**
377-
* Handles the notifiers for the dashboard page.
378-
*
379-
* @deprecated 14.1
380-
* @codeCoverageIgnore
381-
*
382-
* @return void
383-
*/
384-
public function handle_notifications() {
385-
_deprecated_function( __METHOD__, 'WPSEO 14.1' );
386-
}
387334
}

admin/class-admin-user-profile.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ public function process_user_option_update( $user_id ) {
7474
update_user_meta( $user_id, 'wpseo_noindex_author', $this->filter_input_post( 'wpseo_noindex_author' ) );
7575
update_user_meta( $user_id, 'wpseo_content_analysis_disable', $this->filter_input_post( 'wpseo_content_analysis_disable' ) );
7676
update_user_meta( $user_id, 'wpseo_keyword_analysis_disable', $this->filter_input_post( 'wpseo_keyword_analysis_disable' ) );
77+
update_user_meta( $user_id, 'wpseo_inclusive_language_analysis_disable', $this->filter_input_post( 'wpseo_inclusive_language_analysis_disable' ) );
7778
}
7879

7980
/**

admin/class-expose-shortlinks.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ class WPSEO_Expose_Shortlinks implements WPSEO_WordPress_Integration {
5353
'shortlinks.upsell.metabox.word_complexity' => 'https://yoa.st/word-complexity-metabox',
5454
'shortlinks.upsell.gsc.create_redirect_button' => 'https://yoa.st/redirects',
5555
'shortlinks.readability_analysis_info' => 'https://yoa.st/readability-analysis',
56+
'shortlinks.inclusive_language_analysis_info' => 'https://yoa.st/inclusive-language-analysis',
5657
'shortlinks.activate_premium_info' => 'https://yoa.st/activate-subscription',
5758
'shortlinks.upsell.sidebar.morphology_upsell_metabox' => 'https://yoa.st/morphology-upsell-metabox',
5859
'shortlinks.upsell.sidebar.morphology_upsell_sidebar' => 'https://yoa.st/morphology-upsell-sidebar',

admin/class-gutenberg-compatibility.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ class WPSEO_Gutenberg_Compatibility {
1515
*
1616
* @var string
1717
*/
18-
const CURRENT_RELEASE = '14.5.0';
18+
const CURRENT_RELEASE = '14.6.1';
1919

2020
/**
2121
* The minimally supported version of Gutenberg by the plugin.
2222
*
2323
* @var string
2424
*/
25-
const MINIMUM_SUPPORTED = '14.5.0';
25+
const MINIMUM_SUPPORTED = '14.6.1';
2626

2727
/**
2828
* Holds the current version.

admin/class-yoast-notifications.php

Lines changed: 0 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -108,18 +108,6 @@ public function enqueue_assets() {
108108
}
109109
}
110110

111-
/**
112-
* Deprecated: Handle ajax request to dismiss a alert.
113-
* Renamed to ajax_dismiss_notification
114-
*
115-
* @deprecated 14.0
116-
*
117-
* @codeCoverageIgnore
118-
*/
119-
public function ajax_dismiss_alert() {
120-
_deprecated_function( __METHOD__, 'WPSEO 14.0' );
121-
}
122-
123111
/**
124112
* Handle ajax request to dismiss a notification.
125113
*/
@@ -136,19 +124,6 @@ public function ajax_dismiss_notification() {
136124
wp_die();
137125
}
138126

139-
/**
140-
* Deprecated: Handle ajax request to restore a notification.
141-
* Renamed to ajax_restore_notification
142-
*
143-
* @deprecated 14.0
144-
* @codeCoverageIgnore
145-
*
146-
* @return void
147-
*/
148-
public function ajax_restore_alert() {
149-
_deprecated_function( __METHOD__, 'WPSEO 14.0' );
150-
}
151-
152127
/**
153128
* Handle ajax request to restore a notification.
154129
*/
@@ -277,20 +252,6 @@ public static function get_template_variables() {
277252
];
278253
}
279254

280-
/**
281-
* Deprecated: Get the number of active notifications.
282-
* Renamed to get_active_notification_count
283-
*
284-
* @deprecated 14.0
285-
* @codeCoverageIgnore
286-
*
287-
* @return int
288-
*/
289-
public function get_active_alert_count() {
290-
_deprecated_function( __METHOD__, 'WPSEO 14.0' );
291-
return 0;
292-
}
293-
294255
/**
295256
* Get the number of active notifications.
296257
*
@@ -301,20 +262,6 @@ public static function get_active_notification_count() {
301262
return ( count( self::$active_errors ) + count( self::$active_warnings ) );
302263
}
303264

304-
/**
305-
* Deprecated: Filter out any non-errors. Renamed to filter_error_notifications
306-
*
307-
* @deprecated 14.0
308-
* @codeCoverageIgnore
309-
*
310-
* @param Yoast_Notification $notification Notification to test.
311-
* @return bool
312-
*/
313-
public function filter_error_alerts( Yoast_Notification $notification ) {
314-
_deprecated_function( __METHOD__, 'WPSEO 14.0' );
315-
return false;
316-
}
317-
318265
/**
319266
* Filter out any non-errors.
320267
*
@@ -327,20 +274,6 @@ private static function filter_error_notifications( Yoast_Notification $notifica
327274
return $notification->get_type() === 'error';
328275
}
329276

330-
/**
331-
* Deprecated: Filter out any non-warnings. Renamed to filter_warning_notifications
332-
*
333-
* @deprecated 14.0
334-
* @codeCoverageIgnore
335-
*
336-
* @param Yoast_Notification $notification Notification to test.
337-
* @return bool
338-
*/
339-
public function filter_warning_alerts( Yoast_Notification $notification ) {
340-
_deprecated_function( __METHOD__, 'WPSEO 14.0' );
341-
return false;
342-
}
343-
344277
/**
345278
* Filter out any non-warnings.
346279
*
@@ -353,20 +286,6 @@ private static function filter_warning_notifications( Yoast_Notification $notifi
353286
return $notification->get_type() !== 'error';
354287
}
355288

356-
/**
357-
* Deprecated: Filter out any dismissed notifications. Renamed to filter_dismissed_alerts.
358-
*
359-
* @deprecated 14.0
360-
* @codeCoverageIgnore
361-
*
362-
* @param Yoast_Notification $notification Notification to test.
363-
* @return bool
364-
*/
365-
public function filter_dismissed_alerts( Yoast_Notification $notification ) {
366-
_deprecated_function( __METHOD__, 'WPSEO 14.0' );
367-
return false;
368-
}
369-
370289
/**
371290
* Filter out any dismissed notifications.
372291
*

admin/class-yoast-plugin-conflict.php

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -111,41 +111,6 @@ public function check_for_conflicts( $plugin_section ) {
111111
return false;
112112
}
113113

114-
/**
115-
* Getting all the conflicting plugins and return them as a string.
116-
*
117-
* This method will loop through all conflicting plugins to get the details of each plugin. The plugin name
118-
* will be taken from the details to parse a comma separated string, which can be use for by example a notice
119-
*
120-
* @deprecated 17.7 This method is unused and will be removed in the future
121-
* @codeCoverageIgnore
122-
*
123-
* @param string $plugin_section Plugin conflict type (such as Open Graph or sitemap).
124-
*
125-
* @return string
126-
*/
127-
public function get_conflicting_plugins_as_string( $plugin_section ) {
128-
if ( ! \function_exists( 'get_plugin_data' ) ) {
129-
require_once ABSPATH . 'wp-admin/includes/plugin.php';
130-
}
131-
132-
// Getting the active plugins by given section.
133-
$plugins = $this->active_conflicting_plugins[ $plugin_section ];
134-
135-
$plugin_names = [];
136-
foreach ( $plugins as $plugin ) {
137-
$name = $this->get_plugin_name( $plugin );
138-
if ( ! empty( $name ) ) {
139-
$plugin_names[] = '<em>' . $name . '</em>';
140-
}
141-
}
142-
unset( $plugins, $plugin );
143-
144-
if ( ! empty( $plugin_names ) ) {
145-
return \implode( ' &amp; ', $plugin_names );
146-
}
147-
}
148-
149114
/**
150115
* Checks for given $plugin_sections for conflicts.
151116
*

0 commit comments

Comments
 (0)