mirror of
https://github.com/WordPress/WordPress.git
synced 2024-06-27 23:35:04 +02:00
Editor: Check if mb_strtolower
exists before using it in the font library.
Prevents an error when uploading fonts on certain systems, because the `mbstring` extension can be missing and thus the function may not be available. Reviewed by jorbin. Merges [57865] to the to the 6.5 branch. Props mujuonly, swissspidy, peterwilsoncc. Fixes #60823. See #55603. Built from https://develop.svn.wordpress.org/branches/6.5@57869 git-svn-id: http://core.svn.wordpress.org/branches/6.5@57370 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
abedb8faca
commit
609157125d
|
@ -110,8 +110,11 @@ class WP_Font_Utils {
|
|||
'unicodeRange' => 'U+0-10FFFF',
|
||||
);
|
||||
$settings = wp_parse_args( $settings, $defaults );
|
||||
|
||||
$font_family = mb_strtolower( $settings['fontFamily'] );
|
||||
if ( function_exists( 'mb_strtolower' ) ) {
|
||||
$font_family = mb_strtolower( $settings['fontFamily'] );
|
||||
} else {
|
||||
$font_family = strtolower( $settings['fontFamily'] );
|
||||
}
|
||||
$font_style = strtolower( $settings['fontStyle'] );
|
||||
$font_weight = strtolower( $settings['fontWeight'] );
|
||||
$font_stretch = strtolower( $settings['fontStretch'] );
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.5-RC3-57866';
|
||||
$wp_version = '6.5-RC3-57869';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue
Block a user