@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

Fix "Register with Approval flow" for php 8

Summary: Ref T15064.

Test Plan:
- Register as a new user
- as admin, view user's page and approve it
- As new user, hit "wait patiently" to go back to Home

No crashes in this flow.

Reviewers: O1 Blessed Committers, chris

Reviewed By: O1 Blessed Committers, chris

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

Maniphest Tasks: T15064

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

+4 -2
+1 -1
src/applications/auth/controller/PhabricatorAuthNeedsApprovalController.php
··· 51 51 $viewer, 52 52 PhabricatorAuthWaitForApprovalMessageType::MESSAGEKEY); 53 53 54 - if (!strlen($text)) { 54 + if (!phutil_nonempty_string($text)) { 55 55 return null; 56 56 } 57 57
+2
src/applications/auth/engine/PhabricatorAuthPasswordEngine.php
··· 150 150 $base_uri = new PhutilURI($base_uri); 151 151 $blocklist[] = $base_uri->getDomain(); 152 152 153 + $blocklist = array_filter($blocklist); 154 + 153 155 // Generate additional subterms by splitting the raw blocklist on 154 156 // characters like "@", " " (space), and "." to break up email addresses, 155 157 // readable names, and domain names into components.
+1 -1
src/infrastructure/customfield/standard/PhabricatorStandardCustomField.php
··· 301 301 } 302 302 303 303 public function renderPropertyViewValue(array $handles) { 304 - if (!strlen($this->getFieldValue())) { 304 + if (!phutil_nonempty_string($this->getFieldValue())) { 305 305 return null; 306 306 } 307 307 return $this->getFieldValue();