@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix PHP 8.1 "trim(null)" exception which blocks rendering Reports' Burnup Rate page

Summary:
Since PHP 8.1, passing a null string to `trim()` is deprecated.

Thus first check that $row['oldValue'] is not null before trimming it.

Closes T15392

Test Plan: Applied this change; afterwards "Burnup Rate" page at `/maniphest/report/burn/` got correctly rendered in web browser.

Reviewers: O1 Blessed Committers, valerio.bozzolan

Reviewed By: O1 Blessed Committers, valerio.bozzolan

Subscribers: speck, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno

Maniphest Tasks: T15392

Differential Revision: https://we.phorge.it/D25224

+4 -1
+4 -1
src/applications/maniphest/controller/ManiphestReportController.php
··· 186 186 switch ($row['transactionType']) { 187 187 case ManiphestTaskStatusTransaction::TRANSACTIONTYPE: 188 188 // NOTE: Hack to avoid json_decode(). 189 - $oldv = trim($row['oldValue'], '"'); 189 + $oldv = $row['oldValue']; 190 + if ($oldv !== null) { 191 + $oldv = trim($oldv, '"'); 192 + } 190 193 $newv = trim($row['newValue'], '"'); 191 194 break; 192 195 case ManiphestTaskMergedIntoTransaction::TRANSACTIONTYPE: