depot/third_party/nixpkgs/pkgs/development/tools/misc/arcanist/shellcomplete-strlen-null.patch
Default email 3a4df29a92 Project import generated by Copybara.
GitOrigin-RevId: 3d7435c638baffaa826b85459df0fff47f12317d
2022-06-16 19:23:12 +02:00

13 lines
599 B
Diff

diff --git a/src/toolset/workflow/ArcanistShellCompleteWorkflow.php b/src/toolset/workflow/ArcanistShellCompleteWorkflow.php
index 9c2fcf9a..307231c8 100644
--- a/src/toolset/workflow/ArcanistShellCompleteWorkflow.php
+++ b/src/toolset/workflow/ArcanistShellCompleteWorkflow.php
@@ -92,7 +92,7 @@ EOTEXT
$argv = $this->getArgument('argv');
$is_generate = $this->getArgument('generate');
- $is_shell = (bool)strlen($this->getArgument('shell'));
+ $is_shell = phutil_nonempty_string($this->getArgument('shell'));
$is_current = $this->getArgument('current');
if ($argv) {