Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2909436
D25147.1737395011.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
D25147.1737395011.diff
View Options
diff --git a/src/applications/files/controller/PhabricatorFileDataController.php b/src/applications/files/controller/PhabricatorFileDataController.php
--- a/src/applications/files/controller/PhabricatorFileDataController.php
+++ b/src/applications/files/controller/PhabricatorFileDataController.php
@@ -29,7 +29,7 @@
$request_kind = $request->getURIData('kind');
$is_download = ($request_kind === 'download');
- if (!strlen($alt) || $main_domain == $alt_domain) {
+ if (!phutil_nonempty_string($alt) || $main_domain == $alt_domain) {
// No alternate domain.
$should_redirect = false;
$is_alternate_domain = false;
diff --git a/src/applications/search/field/PhabricatorSearchDateField.php b/src/applications/search/field/PhabricatorSearchDateField.php
--- a/src/applications/search/field/PhabricatorSearchDateField.php
+++ b/src/applications/search/field/PhabricatorSearchDateField.php
@@ -17,7 +17,7 @@
}
protected function validateControlValue($value) {
- if (!strlen($value)) {
+ if (!phutil_nonempty_string($value)) {
return;
}
@@ -32,7 +32,7 @@
}
protected function parseDateTime($value) {
- if (!strlen($value)) {
+ if (!phutil_nonempty_string($value)) {
return null;
}
diff --git a/src/view/layout/AphrontSideNavFilterView.php b/src/view/layout/AphrontSideNavFilterView.php
--- a/src/view/layout/AphrontSideNavFilterView.php
+++ b/src/view/layout/AphrontSideNavFilterView.php
@@ -97,7 +97,7 @@
->setName($name)
->setType($type);
- if (strlen($icon)) {
+ if (phutil_nonempty_string($icon)) {
$item->setIcon($icon);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jan 20, 17:43 (1 d, 13 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1133863
Default Alt Text
D25147.1737395011.diff (1 KB)
Attached To
Mode
D25147: Fix PHP 8.1 "strlen(null)" exceptions which block rendering the People page
Attached
Detach File
Event Timeline
Log In to Comment