Page MenuHomePhorge

D25144.1737395170.diff
No OneTemporary

D25144.1737395170.diff

diff --git a/src/applications/meta/query/PhabricatorAppSearchEngine.php b/src/applications/meta/query/PhabricatorAppSearchEngine.php
--- a/src/applications/meta/query/PhabricatorAppSearchEngine.php
+++ b/src/applications/meta/query/PhabricatorAppSearchEngine.php
@@ -45,7 +45,7 @@
->withUnlisted(false);
$name = $saved->getParameter('name');
- if (strlen($name)) {
+ if (phutil_nonempty_string($name)) {
$query->withNameContains($name);
}
diff --git a/src/applications/search/controller/PhabricatorApplicationSearchController.php b/src/applications/search/controller/PhabricatorApplicationSearchController.php
--- a/src/applications/search/controller/PhabricatorApplicationSearchController.php
+++ b/src/applications/search/controller/PhabricatorApplicationSearchController.php
@@ -115,7 +115,7 @@
if ($this->queryKey == 'advanced') {
$run_query = false;
$query_key = $request->getStr('query');
- } else if (!strlen($this->queryKey)) {
+ } else if (!phutil_nonempty_string($this->queryKey)) {
$found_query_data = false;
if ($request->isHTTPGet() || $request->isQuicksand()) {
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
@@ -145,7 +145,7 @@
public function selectFilter($key, $default = null) {
$this->selectedFilter = $default;
- if ($this->menu->getItem($key) && strlen($key)) {
+ if ($this->menu->getItem($key) && phutil_nonempty_string($key)) {
$this->selectedFilter = $key;
}
return $this->selectedFilter;

File Metadata

Mime Type
text/plain
Expires
Mon, Jan 20, 17:46 (1 w, 2 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1130912
Default Alt Text
D25144.1737395170.diff (1 KB)

Event Timeline