Skip to content

Commit a0fb344

Browse files
committed
Fix PHP 8.1 auth view strlen(null) error
Summary: Trying to view a Jira auth provider from https://my.phorge.site/auth/ results in strlen(): Passing null to parameter freebsd#1 ($string) of type string is deprecated This change fixes it Fixes T15634 Test Plan: Go to https://my.phorge.site/auth/ and have a Jira already setup. Click on Jira auth provider Confirm the page is displayed and no error is generated. Reviewers: O1 Blessed Committers, valerio.bozzolan Reviewed By: O1 Blessed Committers, valerio.bozzolan Subscribers: tobiaswiese, valerio.bozzolan, Matthew, Cigaryno Maniphest Tasks: T15634 Differential Revision: https://we.phorge.it/D25432
1 parent a65061d commit a0fb344

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: src/applications/auth/storage/PhabricatorAuthProviderConfigTransaction.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ public function getTitle() {
150150
$provider = $this->getProvider();
151151
if ($provider) {
152152
$title = $provider->renderConfigPropertyTransactionTitle($this);
153-
if (strlen($title)) {
153+
if (phutil_nonempty_string($title)) {
154154
return $title;
155155
}
156156
}

0 commit comments

Comments
 (0)