mirror of
https://we.phorge.it/source/arcanist.git
synced 2024-11-25 00:02:40 +01:00
Do not pass a null string to mb_convert_case() for PHP 8.1 compatibility
Summary: Passing `null` to the `$string` parameter of `mb_convert_case()` is deprecated in PHP 8.1. This is one of the exceptions which block rendering the "Browse Projects" overlay dialog. Closes part of T15335 Test Plan: Applied this change in Arcanist (plus the four changes in D25179 in Phorge) and the `Browse Projects` overlay dialog finally rendered in web browser and listed existing projects. Reviewers: O1 Blessed Committers, valerio.bozzolan Reviewed By: O1 Blessed Committers, valerio.bozzolan Subscribers: speck, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno Maniphest Tasks: T15335 Differential Revision: https://we.phorge.it/D25180
This commit is contained in:
parent
084303cd5f
commit
f7d5614ca1
1 changed files with 3 additions and 0 deletions
|
@ -789,6 +789,9 @@ function phutil_utf8_ucwords($str) {
|
|||
* @phutil-external-symbol function mb_convert_case
|
||||
*/
|
||||
function phutil_utf8_strtolower($str) {
|
||||
if ($str === null) {
|
||||
return '';
|
||||
}
|
||||
if (function_exists('mb_convert_case')) {
|
||||
return mb_convert_case($str, MB_CASE_LOWER, 'UTF-8');
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue