PluginProbe
Yoast SEO – Advanced SEO with real-time guidance and built-in AI / 28.5
Yoast SEO – Advanced SEO with real-time guidance and built-in AI v28.5
28.5 28.4 28.3 28.2 28.1 28.0 27.9 27.8 27.7 27.6 27.5 trunk 18.0 18.1 18.2 18.3 18.4 18.4.1 18.5 18.5.1 18.6 18.7 18.8 18.9 19.0 All 129 releases
← All changes | inc/wpseo-functions.php +2 -79 18.428.5 View file →
@@ -181,23 +181,8 @@
181 181 }
182 182
183 183 add_filter( 'icl_wpml_config_array', 'wpseo_wpml_config' );
184 184
185 -/**
186 - * Yoast SEO breadcrumb shortcode.
187 - * [wpseo_breadcrumb]
188 - *
189 - * @deprecated 14.0
190 - * @codeCoverageIgnore
191 - *
192 - * @return string
193 - */
194 -function wpseo_shortcode_yoast_breadcrumb() {
195 - _deprecated_function( __FUNCTION__, 'WPSEO 14.0' );
196 -
197 - return '';
198 -}
199 -
200 185 if ( ! function_exists( 'ctype_digit' ) ) {
201 186 /**
202 187 * Emulate PHP native ctype_digit() function for when the ctype extension would be disabled *sigh*.
203 188 * Only emulates the behaviour for when the input is a string, does not handle integer input as ascii value.
@@ -224,8 +209,10 @@
224 209 * @param string $old_term_id Old term id of the taxonomy term that was splitted.
225 210 * @param string $new_term_id New term id of the taxonomy term that was splitted.
226 211 * @param string $term_taxonomy_id Term taxonomy id for the taxonomy that was affected.
227 212 * @param string $taxonomy The taxonomy that the taxonomy term was splitted for.
213 + *
214 + * @return void
228 215 */
229 216 function wpseo_split_shared_term( $old_term_id, $new_term_id, $term_taxonomy_id, $taxonomy ) {
230 217 $tax_meta = get_option( 'wpseo_taxonomy_meta', [] );
231 218
@@ -248,69 +235,5 @@
248 235 if ( ! did_action( 'wpseo_register_capabilities' ) ) {
249 236 do_action( 'wpseo_register_capabilities' );
250 237 }
251 238 return WPSEO_Capability_Manager_Factory::get()->get_capabilities();
252 -}
253 -
254 -if ( ! function_exists( 'wp_get_environment_type' ) ) {
255 - /**
256 - * Retrieves the current environment type.
257 - *
258 - * The type can be set via the `WP_ENVIRONMENT_TYPE` global system variable,
259 - * or a constant of the same name.
260 - *
261 - * Possible values include 'local', 'development', 'staging', 'production'.
262 - * If not set, the type defaults to 'production'.
263 - *
264 - * Backfill for `wp_get_environment_type()` introduced in WordPress 5.5. Code
265 - * is adapted to the Yoast PHP coding standards.
266 - *
267 - * @return string The current environment type.
268 - */
269 - function wp_get_environment_type() {
270 - static $current_env = '';
271 -
272 - if ( $current_env ) {
273 - return $current_env;
274 - }
275 -
276 - $wp_environments = [
277 - 'local',
278 - 'development',
279 - 'staging',
280 - 'production',
281 - ];
282 -
283 - // Check if the environment variable has been set, if `getenv` is available on the system.
284 - if ( function_exists( 'getenv' ) ) {
285 - $has_env = getenv( 'WP_ENVIRONMENT_TYPES' );
286 - if ( $has_env !== false ) {
287 - $wp_environments = explode( ',', $has_env );
288 - }
289 - }
290 -
291 - // Fetch the environment types from a constant, this overrides the global system variable.
292 - if ( defined( 'WP_ENVIRONMENT_TYPES' ) ) {
293 - $wp_environments = WP_ENVIRONMENT_TYPES;
294 - }
295 -
296 - // Check if the environment variable has been set, if `getenv` is available on the system.
297 - if ( function_exists( 'getenv' ) ) {
298 - $has_env = getenv( 'WP_ENVIRONMENT_TYPE' );
299 - if ( $has_env !== false ) {
300 - $current_env = $has_env;
301 - }
302 - }
303 -
304 - // Fetch the environment from a constant, this overrides the global system variable.
305 - if ( defined( 'WP_ENVIRONMENT_TYPE' ) ) {
306 - $current_env = WP_ENVIRONMENT_TYPE;
307 - }
308 -
309 - // Make sure the environment is an allowed one, and not accidentally set to an invalid value.
310 - if ( ! in_array( $current_env, $wp_environments, true ) ) {
311 - $current_env = 'production';
312 - }
313 -
314 - return $current_env;
315 - }
316 239 }