mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-26 00:32:42 +01:00
Fix PHP 8.1 "explode(null)" exception which blocks rendering "Provide Multi-Factor Credentials" page
Summary: Passing null to the `$string` in `explode(string $separator, string $string, int $limit)` is deprecated since PHP 8.1. Thus do not explode but create an empty array if the input is null. Closes T15397 Test Plan: Applied this change and afterwards the "Provide Multi-Factor Credentials" page at `/auth/finish/` showing the "App Code" field correctly rendered in the web browser. Reviewers: O1 Blessed Committers, valerio.bozzolan Reviewed By: O1 Blessed Committers, valerio.bozzolan Subscribers: speck, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno Maniphest Tasks: T15397 Differential Revision: https://we.phorge.it/D25229
This commit is contained in:
parent
c1c7699c98
commit
10fae71a04
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ final class PhabricatorAuthChallenge
|
||||||
AphrontRequest $request) {
|
AphrontRequest $request) {
|
||||||
assert_instances_of($challenges, __CLASS__);
|
assert_instances_of($challenges, __CLASS__);
|
||||||
|
|
||||||
$token_list = $request->getStr(self::HTTPKEY);
|
$token_list = $request->getStr(self::HTTPKEY, '');
|
||||||
$token_list = explode(' ', $token_list);
|
$token_list = explode(' ', $token_list);
|
||||||
|
|
||||||
$token_map = array();
|
$token_map = array();
|
||||||
|
|
Loading…
Reference in a new issue