1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-02-01 17:38:24 +01:00
phorge-phorge/src/applications/paste
Andre Klapper 279ed1ee76 Fix PHP 8.1 "strlen(null)" exception in PhabricatorPasteLanguageTransaction.php
Summary:
`strlen()` was used in Phabricator to check if a generic value is a non-empty string.
This behavior is deprecated since PHP 8.1. Phorge adopts `phutil_nonempty_string()` as a replacement.

Note: this may highlight other absurd input values that might be worth correcting
instead of just ignoring. If phutil_nonempty_string() throws an exception in your
instance, report it to Phorge to evaluate and fix that specific corner case.

Closes T15808

Test Plan: Unknown. Given that the function rendering `$value` is later called to construct a title string passed to `pht()` I assume that it should be a string and not a scalar.

Reviewers: O1 Blessed Committers, speck

Reviewed By: O1 Blessed Committers, speck

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

Maniphest Tasks: T15808

Differential Revision: https://we.phorge.it/D25611
2024-05-02 10:28:08 +02:00
..
application Show more in Application Detail and List view 2023-11-21 11:22:23 -07:00
capability Paste: Add edit policy 2014-12-31 08:24:57 -08:00
conduit Fix PHP 8.1 "strlen(null)" exception creating a Paste without content in Conduit paste.create 2023-08-18 09:48:41 +02:00
controller When a Paste has a useful alternative rendering in Files, provide a hint 2020-05-01 09:09:42 -07:00
editor Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string 2024-02-05 14:11:36 +01:00
engine Add Ferret support to Paste 2020-04-16 14:10:23 -07:00
engineextension Give "owners.search" a "paths" attachment and a default "owners" value 2015-12-14 11:53:50 -08:00
lipsum Fix Lipsum generators for Differential Revisions and Pastes 2018-07-23 15:05:51 -05:00
mail Remove "metamta.*.subject-prefix" options 2019-01-17 19:18:50 -08:00
phid Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string 2024-02-05 14:11:36 +01:00
query Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string 2024-02-05 14:11:36 +01:00
remarkup Add some missing type hints 2015-05-05 07:33:00 +10:00
snippet Display paste line count alongside snippets 2017-01-26 19:06:23 -05:00
storage Add Ferret support to Paste 2020-04-16 14:10:23 -07:00
typeahead Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string 2024-02-05 14:11:36 +01:00
view Return $this from setter methods 2015-07-06 22:53:43 +10:00
xaction Fix PHP 8.1 "strlen(null)" exception in PhabricatorPasteLanguageTransaction.php 2024-05-02 10:28:08 +02:00