Page MenuHomePhorge

Fix PHP 8.1 auth view strlen(null) error
ClosedPublic

Authored by Sten on Sep 5 2023, 14:16.
Tags
None
Referenced Files
F3301681: D25432.1743056659.diff
Wed, Mar 26, 06:24
F3298361: D25432.1743000869.diff
Tue, Mar 25, 14:54
F3298329: D25432.1743000099.diff
Tue, Mar 25, 14:41
F3296378: D25432.1742972219.diff
Tue, Mar 25, 06:56
F3273239: D25432.1742560894.diff
Thu, Mar 20, 12:41
F3249261: D25432.1742285399.diff
Mon, Mar 17, 08:09
F3209846: D25432.1741439941.diff
Fri, Mar 7, 13:19
F3037712: D25432.1740929854.diff
Sat, Mar 1, 15:37

Details

Summary

Trying to view a Jira auth provider from https://my.phorge.site/auth/ results in strlen(): Passing null to parameter #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.

Diff Detail

Repository
rP Phorge
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Sten requested review of this revision.Sep 5 2023, 14:16

I tried to test this but I have not a real JIRA account and I was not able to test a non-null value. But, I inspected all the definitions of that method and it seems it only returns pht() so I would assume that it only returns strings.

This revision is now accepted and ready to land.Sep 10 2023, 00:27