1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-02-07 12:28:28 +01:00
phorge-phorge/src/applications/spaces
Andre Klapper 25aebab655 Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string
Summary:
`::class` is available since PHP 5.5 (5.5 is a minimal requirement by Phorge): https://www.php.net/manual/en/language.oop5.basic.php#language.oop5.basic.class.class
It makes finding code using IDEs easier; see discussion in D25500.

Thus replace all string return values with returning the `::class` constant instead, with one exception: 'PhabricatorSettingApplication' in `PhabricatorUserPreferencesSearchEngine.php` does not exist and makes arc lint fail so this string remained unchanged.

Also note that two occurrences were wrapped in `pht()` for reasons I do not know.

List of functions whose return value get updated in this code change:
* getApplicationClassName()
* getAdapterApplicationClass()
* getDatasourceApplicationClass()
* getEditorApplicationClass()
* getEngineApplicationClass()
* getPHIDTypeApplicationClass()
* getQueryApplicationClass()

cf. T15158

Test Plan: Too broad - click around, basically.

Reviewers: O1 Blessed Committers, valerio.bozzolan

Reviewed By: O1 Blessed Committers, valerio.bozzolan

Subscribers: tobiaswiese, valerio.bozzolan, Matthew, Cigaryno

Maniphest Tasks: T15158

Differential Revision: https://we.phorge.it/D25524
2024-02-05 14:11:36 +01:00
..
__tests__ Update Spaces for modular transactions 2017-05-04 21:48:13 +00:00
application Show more in Application Detail and List view 2023-11-21 11:22:23 -07:00
capability Add "Spaces", an application for managing policy namespaces 2015-06-01 11:28:38 -07:00
controller Remove "Editable By" description fields in Passphrase, Phame, and Spaces 2019-09-12 09:36:50 -07:00
editor Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string 2024-02-05 14:11:36 +01:00
engineextension Add more mail stamps: tasks, subscribers, projects, spaces 2018-02-06 04:05:46 -08:00
herald Group and order Herald fields 2015-07-16 14:13:13 -07:00
interface Add spacePHID infrastructure and implement in Paste 2015-06-04 17:45:24 -07: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 a Spaces remarkup rule 2015-06-05 14:19:40 -07:00
searchfield Flesh out Conduit types for Paste search fields 2015-12-14 04:23:28 -08:00
storage Make the default behavior of getApplicationTransactionCommentObject() "return null" instead of "throw" 2019-02-07 14:56:38 -08:00
typeahead Make misc get*ApplicationClass[Name]() calls return ::class constant instead of string 2024-02-05 14:11:36 +01:00
view Don't show Space monograms in SpaceContextView 2015-06-11 10:14:22 -07:00
xaction Fix PHP 8.1 "strlen(null)" exception which blocks Space creation 2023-05-06 04:05:37 +02:00